Closed xephosbot closed 1 year ago
See https://core.telegram.org/tdlib/getting-started#getting-the-lists-of-chats. Basically, you need to listen to updates and change chat order based on the updates. If you receive 404 from loadChats
, then all relevant updates has already been sent.
And how do I control the order of updates? For example, if the chat update event came with chatId before I got it from newChatUpdate.
And so, if I need to load messages from all ChatList then I need to call multiple times loadChats with the required chatList? Until I call loadChats from ChatListArchive or ChatListFolder, the chat updates won't come from there?
The updates for a chat list can be received if loading of the chat list is required to answer some other request besides loadChats
.
Following the Java example, I recursively call the LoadChats method until I get a 404 error. However, I get this error even when less than half of the chats are loaded.