2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 22:46:10 +00:00

Add revoking of full history.

This commit is contained in:
John Preston
2019-03-21 17:48:40 +04:00
parent 33069739ee
commit eb1825defd
9 changed files with 130 additions and 113 deletions

View File

@@ -648,6 +648,12 @@ Data::RestrictionCheckResult PeerData::amRestricted(
return Result::Allowed();
}
bool PeerData::canRevokeFullHistory() const {
return isUser()
&& Global::RevokePrivateInbox()
&& (Global::RevokePrivateTimeLimit() == 0x7FFFFFFF);
}
namespace Data {
std::vector<ChatRestrictions> ListOfRestrictions() {