From 400d4b793a632151b9dd13c7d8881632f014bfbd Mon Sep 17 00:00:00 2001 From: John Preston Date: Tue, 6 Sep 2022 08:09:29 +0400 Subject: [PATCH] Fix initial visibility of Who can send messages. Fixes #25030. --- Telegram/SourceFiles/boxes/peers/edit_peer_type_box.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Telegram/SourceFiles/boxes/peers/edit_peer_type_box.cpp b/Telegram/SourceFiles/boxes/peers/edit_peer_type_box.cpp index ad5f472a5..4ba265e0a 100644 --- a/Telegram/SourceFiles/boxes/peers/edit_peer_type_box.cpp +++ b/Telegram/SourceFiles/boxes/peers/edit_peer_type_box.cpp @@ -241,6 +241,10 @@ void Controller::createContent() { ) | rpl::start_with_next([=](bool toggled) { _dataSavedValue->joinToWrite = toggled; }, wrap->lifetime()); + } else { + _controls.whoSendWrap->toggle( + (_controls.privacy->value() == Privacy::HasUsername), + anim::type::instant); } auto joinToWrite = _controls.joinToWrite ? _controls.joinToWrite->toggledValue()