mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2024-11-29 21:03:45 +03:00
Fix message.text behaviour with no parse mode
This commit is contained in:
parent
383ab9b0b2
commit
465f38c1c6
|
@ -268,7 +268,10 @@ class Message(ChatGetter, SenderGetter, TLObject, abc.ABC):
|
||||||
The message text, formatted using the client's default
|
The message text, formatted using the client's default
|
||||||
parse mode. Will be ``None`` for :tl:`MessageService`.
|
parse mode. Will be ``None`` for :tl:`MessageService`.
|
||||||
"""
|
"""
|
||||||
if self._text is None and self._client and self._client.parse_mode:
|
if self._text is None and self._client:
|
||||||
|
if not self._client.parse_mode:
|
||||||
|
self._text = self.message
|
||||||
|
else:
|
||||||
self._text = self._client.parse_mode.unparse(
|
self._text = self._client.parse_mode.unparse(
|
||||||
self.message, self.entities)
|
self.message, self.entities)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user