Disallow "Disable Sharing" for service users.

This commit is contained in:
John Preston
2026-03-31 15:57:42 +07:00
parent 27b041c4c5
commit 8f56ef4502
@@ -1434,7 +1434,11 @@ void ShowDisableSharingBox(
void Filler::addToggleNoForwards() {
const auto user = _peer->asUser();
if (!user || user->isInaccessible() || user->isBot() || user->isSelf()) {
if (!user
|| user->isInaccessible()
|| user->isBot()
|| user->isServiceUser()
|| user->isSelf()) {
return;
}
const auto controller = _controller;