Don't init BackgroundManager for bots.

This commit is contained in:
levlam 2024-01-24 14:48:17 +03:00
parent 0c0c24e7d0
commit 13c94c7731

View File

@ -412,6 +412,10 @@ class BackgroundManager::BackgroundsLogEvent {
};
void BackgroundManager::start_up() {
if (td_->auth_manager_->is_bot()) {
return;
}
max_local_background_id_ = BackgroundId(to_integer<int64>(G()->td_db()->get_binlog_pmc()->get("max_bg_id")));
// first parse all log events and fix max_local_background_id_ value