From a49806bf79f6521efd92d33edeaa2b6c33d74b2b Mon Sep 17 00:00:00 2001 From: John Preston Date: Mon, 27 May 2019 15:30:23 +0200 Subject: [PATCH] Only admin can unlink channel from the group. --- Telegram/SourceFiles/boxes/peers/edit_peer_info_box.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Telegram/SourceFiles/boxes/peers/edit_peer_info_box.cpp b/Telegram/SourceFiles/boxes/peers/edit_peer_info_box.cpp index b144dd99c..adb7122d0 100644 --- a/Telegram/SourceFiles/boxes/peers/edit_peer_info_box.cpp +++ b/Telegram/SourceFiles/boxes/peers/edit_peer_info_box.cpp @@ -778,7 +778,9 @@ void Controller::fillManageSection() { ? false : channel->isBroadcast() ? channel->canEditInformation() - : (channel->linkedChat() && channel->canPinMessages()); + : (channel->linkedChat() + && channel->canPinMessages() + && channel->adminRights() != 0); }(); AddSkip(_controls.buttonsLayout, 0);