From 2a52eca5f512e94269a5daf1c27a4cd01292c903 Mon Sep 17 00:00:00 2001 From: John Preston Date: Sun, 18 Feb 2024 20:21:03 +0400 Subject: [PATCH] Fix set icon in updating group emoji set. --- Telegram/SourceFiles/boxes/peers/edit_peer_color_box.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Telegram/SourceFiles/boxes/peers/edit_peer_color_box.cpp b/Telegram/SourceFiles/boxes/peers/edit_peer_color_box.cpp index 4b6f11425..1fbc8c898 100644 --- a/Telegram/SourceFiles/boxes/peers/edit_peer_color_box.cpp +++ b/Telegram/SourceFiles/boxes/peers/edit_peer_color_box.cpp @@ -1036,8 +1036,11 @@ struct ButtonWithEmoji { })); }) | rpl::flatten_latest( ) | rpl::start_with_next([=](DocumentData *icon) { - state->icon = icon; - right->update(); + if (state->icon != icon) { + state->icon = icon; + state->custom = nullptr; + right->update(); + } }, right->lifetime()); return result;