diff --git a/td/telegram/AnimationsManager.cpp b/td/telegram/AnimationsManager.cpp index 62530fc1b..4b9d7a4f3 100644 --- a/td/telegram/AnimationsManager.cpp +++ b/td/telegram/AnimationsManager.cpp @@ -808,7 +808,7 @@ string AnimationsManager::get_animation_search_text(FileId file_id) const { } void AnimationsManager::after_get_difference() { - if (td_->is_online()) { + if (td_->is_online() && !td_->auth_manager_->is_bot()) { get_saved_animations(Auto()); } } diff --git a/td/telegram/ContactsManager.cpp b/td/telegram/ContactsManager.cpp index c83f97c9c..7cacf81bb 100644 --- a/td/telegram/ContactsManager.cpp +++ b/td/telegram/ContactsManager.cpp @@ -12904,6 +12904,9 @@ UserId ContactsManager::get_support_user(Promise &&promise) { } void ContactsManager::after_get_difference() { + if (td_->auth_manager_->is_bot()) { + return; + } get_user(get_my_id(), 3, Promise()); } diff --git a/td/telegram/InlineQueriesManager.cpp b/td/telegram/InlineQueriesManager.cpp index 153e8bf8b..2f8772b94 100644 --- a/td/telegram/InlineQueriesManager.cpp +++ b/td/telegram/InlineQueriesManager.cpp @@ -180,6 +180,9 @@ void InlineQueriesManager::on_drop_inline_query_result_timeout_callback(void *in } void InlineQueriesManager::after_get_difference() { + if (td_->auth_manager_->is_bot()) { + return; + } if (recently_used_bots_loaded_ < 2) { Promise promise; load_recently_used_bots(promise); diff --git a/td/telegram/StickersManager.cpp b/td/telegram/StickersManager.cpp index 4e2aaf7c0..ce93a45cb 100644 --- a/td/telegram/StickersManager.cpp +++ b/td/telegram/StickersManager.cpp @@ -1100,8 +1100,6 @@ void StickersManager::start_up() { add_sticker_set(animated_emoji_sticker_set_id_, animated_emoji_sticker_set_access_hash_); short_name_to_sticker_set_id_.emplace(animated_emoji_sticker_set_name_, animated_emoji_sticker_set_id_); G()->shared_config().set_option_string("animated_emoji_sticker_set_name", animated_emoji_sticker_set_name_); - - td_->create_handler()->send(); } void StickersManager::tear_down() { @@ -5300,6 +5298,9 @@ string StickersManager::remove_emoji_modifiers(string emoji) { } void StickersManager::after_get_difference() { + if (!td_->auth_manager_->is_bot()) { + return; + } if (td_->is_online()) { get_installed_sticker_sets(false, Auto()); get_installed_sticker_sets(true, Auto()); @@ -5307,6 +5308,7 @@ void StickersManager::after_get_difference() { get_recent_stickers(false, Auto()); get_recent_stickers(true, Auto()); get_favorite_stickers(Auto()); + td_->create_handler()->send(); } }