Better dialog pos after loading it from database.

GitOrigin-RevId: 475baad7205fb1843840fb22cb1349a7a4f68ac6
This commit is contained in:
levlam 2018-12-26 23:40:52 +03:00
parent 8eb396ae87
commit 36419ed6c6

View File

@ -22262,6 +22262,9 @@ void MessagesManager::fix_new_dialog(Dialog *d, unique_ptr<Message> &&last_datab
d->pending_last_message_id = last_database_message->message_id;
pending_add_dialog_last_database_message_[dialog_id] = {dependent_dialog_count, std::move(last_database_message)};
}
} else if (last_database_message_id.is_valid()) {
d->pending_last_message_date = DialogDate(order, dialog_id).get_date();
d->pending_last_message_id = last_database_message_id;
}
switch (dialog_id.get_type()) {