Skip service accounts in gift premiums box.

This commit is contained in:
John Preston 2024-01-02 13:29:31 +04:00
parent 676e85983d
commit 0b5f05c7d4
1 changed files with 7 additions and 3 deletions

View File

@ -903,9 +903,13 @@ void GiftPremiumValidator::showChoosePeerBox(const QString &ref) {
protected:
std::unique_ptr<PeerListRow> createRow(
not_null<UserData*> user) override {
return !user->isSelf()
? ContactsBoxController::createRow(user)
: nullptr;
if (user->isSelf()
|| user->isBot()
|| user->isServiceUser()
|| user->isInaccessible()) {
return nullptr;
}
return ContactsBoxController::createRow(user);
}
void rowClicked(not_null<PeerListRow*> row) override {