mirror of
https://github.com/pyrogram/pyrogram
synced 2025-09-07 17:55:24 +00:00
Fix IndexError when parsing empty nearby chats
This commit is contained in:
@@ -57,6 +57,9 @@ class GetNearbyChats(BaseClient):
|
||||
)
|
||||
)
|
||||
|
||||
if not r.updates:
|
||||
return []
|
||||
|
||||
chats = pyrogram.List([pyrogram.Chat._parse_chat(self, chat) for chat in r.chats])
|
||||
peers = r.updates[0].peers
|
||||
|
||||
|
Reference in New Issue
Block a user