mirror of
https://github.com/vale981/tdesktop
synced 2025-03-06 02:01:40 -05:00
Fix remove option in normal groups
If user invites X to group and then X becomes an admin, user won't be able to remove X anymore, so remove option shouldn't be shown. Signed-off-by: Viktor Oreshkin <imselfish@stek29.rocks>
This commit is contained in:
parent
96d1fe336a
commit
bca0e1e16c
1 changed files with 3 additions and 1 deletions
|
@ -398,8 +398,10 @@ void GroupMembersWidget::setItemFlags(Item *item, ChatData *chat) {
|
|||
item->hasRemoveLink = false;
|
||||
} else if (chat->amCreator() || (chat->amAdmin() && !item->hasAdminStar)) {
|
||||
item->hasRemoveLink = true;
|
||||
} else if (chat->invitedByMe.contains(user) && !item->hasAdminStar) {
|
||||
item->hasRemoveLink = true;
|
||||
} else {
|
||||
item->hasRemoveLink = chat->invitedByMe.contains(user);
|
||||
item->hasRemoveLink = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue