mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-09-05 00:46:08 +00:00
Support anonymous group admins.
This commit is contained in:
@@ -790,6 +790,12 @@ Data::RestrictionCheckResult PeerData::amRestricted(
|
||||
return Result::Allowed();
|
||||
}
|
||||
|
||||
bool PeerData::amAnonymous() const {
|
||||
return isBroadcast()
|
||||
|| (isChannel()
|
||||
&& (asChannel()->adminRights() & ChatAdminRight::f_anonymous));
|
||||
}
|
||||
|
||||
bool PeerData::canRevokeFullHistory() const {
|
||||
return isUser()
|
||||
&& !isSelf()
|
||||
|
Reference in New Issue
Block a user