Return produced service message with pin_message

Fixes #1394.
This commit is contained in:
Lonami Exo
2020-04-29 10:29:14 +02:00
parent 74bced75b4
commit c43e2a0a3a
4 changed files with 25 additions and 5 deletions

View File

@@ -898,7 +898,7 @@ class Message(ChatGetter, SenderGetter, TLObject, abc.ABC):
# maybe just make it illegal to call messages from raw API?
# That or figure out a way to always set it directly.
if self._client:
await self._client.pin_message(
return await self._client.pin_message(
await self.get_input_chat(), self.id, notify=notify)
# endregion Public Methods