Remove 'delete also for' in Deleted Accounts.

This commit is contained in:
John Preston 2025-03-13 12:23:23 +04:00
parent d1e4dbb603
commit 06ed6c81a7
3 changed files with 5 additions and 2 deletions

View file

@ -271,7 +271,8 @@ void DeleteMessagesBox::prepare() {
appendDetails({
tr::lng_delete_for_me_chat_hint(tr::now, lt_count, count)
});
} else if (!peer->isSelf()) {
} else if (!peer->isSelf()
&& (!peer->isUser() || !peer->asUser()->isInaccessible())) {
if (const auto user = peer->asUser(); user && user->isBot()) {
_revokeForBot = true;
}

View file

@ -1483,6 +1483,7 @@ bool PeerData::canRevokeFullHistory() const {
if (const auto user = asUser()) {
return !isSelf()
&& (!user->isBot() || user->isSupport())
&& !user->isInaccessible()
&& session().serverConfig().revokePrivateInbox
&& (session().serverConfig().revokePrivateTimeLimit == 0x7FFFFFFF);
} else if (const auto chat = asChat()) {

View file

@ -2413,7 +2413,8 @@ bool HistoryItem::canDeleteForEveryone(TimeId now) const {
} else if (const auto user = peer->asUser()) {
// Bots receive all messages and there is no sense in revoking them.
// See https://github.com/telegramdesktop/tdesktop/issues/3818
if (user->isBot() && !user->isSupport()) {
if ((user->isBot() && !user->isSupport())
|| user->isInaccessible()) {
return false;
}
}