Fixed logging out, added a proper function to list sessions

By fixing logging out, other request probably got fixed as well,
since now we can also read MessagesAcknowledge requests
This commit is contained in:
Lonami
2016-09-23 12:50:01 +02:00
parent d8757af5c5
commit 87969745f5
2 changed files with 20 additions and 4 deletions
+10
View File
@@ -192,6 +192,16 @@ class MtProtoSender:
if code == 0xa7eff811: # bad_msg_notification
return self.handle_bad_msg_notification(msg_id, sequence, reader)
if code == 0x62d6b459: # msgs_ack, it may handle the request we wanted
ack = reader.tgread_object()
for message_id in ack.msg_ids:
if message_id in self.need_confirmation:
self.need_confirmation.remove(message_id)
if request and request.msg_id in ack.msg_ids:
request.confirm_received = True
return False
# If the code is not parsed manually, then it was parsed by the code generator!
# In this case, we will simply treat the incoming TLObject as an Update,
# if we can first find a matching TLObject