diff --git a/td/generate/scheme/td_api.tl b/td/generate/scheme/td_api.tl index 3397265a7..332d36a5d 100644 --- a/td/generate/scheme/td_api.tl +++ b/td/generate/scheme/td_api.tl @@ -4049,6 +4049,9 @@ pushMessageContentChatJoinByRequest = PushMessageContent; //@description A new recurrent payment was made by the current user @amount The paid amount pushMessageContentRecurringPayment amount:string = PushMessageContent; +//@description A profile photo was suggested to the user +pushMessageContentSuggestProfilePhoto = PushMessageContent; + //@description A forwarded messages @total_count Number of forwarded messages pushMessageContentMessageForwards total_count:int32 = PushMessageContent; diff --git a/td/telegram/NotificationManager.cpp b/td/telegram/NotificationManager.cpp index 3f0df1b7b..005a4fecb 100644 --- a/td/telegram/NotificationManager.cpp +++ b/td/telegram/NotificationManager.cpp @@ -2898,6 +2898,9 @@ string NotificationManager::convert_loc_key(const string &loc_key) { if (loc_key == "MESSAGE_STICKER") { return "MESSAGE_STICKER"; } + if (loc_key == "MESSAGE_SUGGEST_PHOTO") { + return "MESSAGE_SUGGEST_PHOTO"; + } break; case 'T': if (loc_key == "CHAT_LEFT") { diff --git a/td/telegram/NotificationType.cpp b/td/telegram/NotificationType.cpp index 557ec4bee..3184c950e 100644 --- a/td/telegram/NotificationType.cpp +++ b/td/telegram/NotificationType.cpp @@ -296,20 +296,23 @@ class NotificationTypePushMessage final : public NotificationType { } break; case 'S': + if (key == "MESSAGE_SCREENSHOT_TAKEN") { + return td_api::make_object(); + } if (key == "MESSAGE_SECRET_PHOTO") { return td_api::make_object(nullptr, arg, true, false); } if (key == "MESSAGE_SECRET_VIDEO") { return td_api::make_object(nullptr, arg, true, false); } - if (key == "MESSAGE_SCREENSHOT_TAKEN") { - return td_api::make_object(); - } if (key == "MESSAGE_STICKER") { auto stickers_manager = G()->td().get_actor_unsafe()->stickers_manager_.get(); return td_api::make_object( stickers_manager->get_sticker_object(document.file_id), trim(arg), is_pinned); } + if (key == "MESSAGE_SUGGEST_PHOTO") { + return td_api::make_object(); + } break; case 'T': if (key == "MESSAGE_TEXT") {