From 2f702148e3492d877143f0437a9119f126ef6d4c Mon Sep 17 00:00:00 2001 From: John Preston Date: Mon, 28 Jan 2019 13:09:46 +0300 Subject: [PATCH] Fix manage channel actions visibility. Fixes #5601. --- Telegram/SourceFiles/data/data_channel.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Telegram/SourceFiles/data/data_channel.cpp b/Telegram/SourceFiles/data/data_channel.cpp index 40f5ed35c..ca757f50c 100644 --- a/Telegram/SourceFiles/data/data_channel.cpp +++ b/Telegram/SourceFiles/data/data_channel.cpp @@ -381,7 +381,9 @@ bool ChannelData::canViewBanned() const { } bool ChannelData::canEditInformation() const { - return !amRestricted(Restriction::f_change_info); + return isMegagroup() + ? !amRestricted(Restriction::f_change_info) + : ((adminRights() & AdminRight::f_change_info) || amCreator()); } bool ChannelData::canEditPermissions() const {