Remove limit on number of preloaded chats.
GitOrigin-RevId: 515a47d04641e23bc8d5f72bbf01568d83dde96d
This commit is contained in:
parent
392b62e40b
commit
3a622cccaf
@ -13251,12 +13251,6 @@ void MessagesManager::preload_dialog_list(FolderId folder_id) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (list.ordered_dialogs_.size() > MAX_PRELOADED_DIALOGS) {
|
||||
// do nothing if there are more than MAX_PRELOADED_DIALOGS dialogs already loaded
|
||||
recalc_unread_count(folder_id);
|
||||
return;
|
||||
}
|
||||
|
||||
if (list.last_loaded_database_dialog_date_ < list.last_database_server_dialog_date_) {
|
||||
// if there are some dialogs in database, preload some of them
|
||||
load_dialog_list(folder_id, 20, true, Auto());
|
||||
|
@ -1460,8 +1460,6 @@ class MessagesManager : public Actor {
|
||||
|
||||
static constexpr int32 MAX_RESEND_DELAY = 86400; // seconds, some resonable limit
|
||||
|
||||
static constexpr int32 MAX_PRELOADED_DIALOGS = 1000;
|
||||
|
||||
static constexpr int32 SCHEDULE_WHEN_ONLINE_DATE = 2147483646;
|
||||
|
||||
static constexpr double DIALOG_ACTION_TIMEOUT = 5.5;
|
||||
|
Reference in New Issue
Block a user