We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 160c71c commit b2b5cb0Copy full SHA for b2b5cb0
pyrogram/methods/messages/delete_messages.py
@@ -93,7 +93,9 @@ async def delete_messages(
93
)
94
for i in r.updates:
95
if isinstance(i, raw.types.UpdateDeleteScheduledMessages):
96
- return len(i.messages)
+ return len(
97
+ getattr(i, "messages", [])
98
+ )
99
else:
100
if isinstance(peer, raw.types.InputPeerChannel):
101
r = await self.invoke(
@@ -110,4 +112,4 @@ async def delete_messages(
110
112
111
113
114
- return r.pts_count
115
+ return getattr(r, "pts_count", 0)
0 commit comments