Update utils to accommodate changes on get_messages
This commit is contained in:
parent
daee188fa5
commit
6cf6d49634
@ -638,7 +638,8 @@ def parse_messages(
|
||||
while True:
|
||||
try:
|
||||
m.reply_to_message = client.get_messages(
|
||||
m.chat.id, message.reply_to_msg_id,
|
||||
m.chat.id,
|
||||
reply_to_message_ids=message.id,
|
||||
replies=replies - 1
|
||||
)
|
||||
except FloodWait as e:
|
||||
@ -750,8 +751,8 @@ def parse_messages(
|
||||
while True:
|
||||
try:
|
||||
m.pinned_message = client.get_messages(
|
||||
m.chat.id, message.reply_to_msg_id,
|
||||
replies=0
|
||||
m.chat.id,
|
||||
message_ids=message.reply_to_msg_id
|
||||
)
|
||||
except FloodWait as e:
|
||||
log.warning("get_messages flood: waiting {} seconds".format(e.x))
|
||||
@ -948,7 +949,7 @@ def parse_chat_full(
|
||||
if full_chat.pinned_msg_id:
|
||||
parsed_chat.pinned_message = client.get_messages(
|
||||
parsed_chat.id,
|
||||
full_chat.pinned_msg_id
|
||||
message_ids=full_chat.pinned_msg_id
|
||||
)
|
||||
|
||||
if isinstance(full_chat.exported_invite, types.ChatInviteExported):
|
||||
|
Loading…
Reference in New Issue
Block a user