mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2025-06-26 06:56:38 +00:00
Make HTML parser yield the correct offset and lengths
This commit is contained in:
parent
d6ec883cd9
commit
d854babf22
@ -98,7 +98,7 @@ class HTMLToTelegramParser(HTMLParser):
|
|||||||
text = url
|
text = url
|
||||||
|
|
||||||
for tag, entity in self._building_entities.items():
|
for tag, entity in self._building_entities.items():
|
||||||
entity.length += len(text.strip('\n'))
|
entity.length += len(text)
|
||||||
|
|
||||||
self.text += text
|
self.text += text
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user