diff --git a/Telegram/SourceFiles/ayu/ui/context_menu/context_menu.cpp b/Telegram/SourceFiles/ayu/ui/context_menu/context_menu.cpp index f4778ee9c7..3e585903f1 100644 --- a/Telegram/SourceFiles/ayu/ui/context_menu/context_menu.cpp +++ b/Telegram/SourceFiles/ayu/ui/context_menu/context_menu.cpp @@ -207,14 +207,19 @@ void AddHideMessageAction(not_null menu, HistoryItem *item) { } const auto history = item->history(); + const auto owner = &history->owner(); menu->addAction( tr::ayu_ContextHideMessage(tr::now), [=]() { - item->destroy(); + const auto ids = owner->itemOrItsGroup(item); + for (const auto &fullId : ids) { + if (const auto current = owner->message(fullId)) { + current->destroy(); + AyuState::hide(current); + } + } history->requestChatListMessage(); - - AyuState::hide(item); }, &st::menuIconClear); }