mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 06:35:51 +00:00
Support admins with empty rights
This commit is contained in:
@@ -408,7 +408,7 @@ public final class ChannelMembersSearchContainerNode: SearchDisplayControllerCon
|
||||
|
||||
if peerId.namespace == Namespaces.Peer.CloudChannel {
|
||||
if case .searchAdmins = mode {
|
||||
return context.peerChannelMemberCategoriesContextsManager.updateMemberAdminRights(account: context.account, peerId: peerId, memberId: memberId, adminRights: TelegramChatAdminRights(flags: []), rank: nil)
|
||||
return context.peerChannelMemberCategoriesContextsManager.updateMemberAdminRights(account: context.account, peerId: peerId, memberId: memberId, adminRights: nil, rank: nil)
|
||||
|> `catch` { _ -> Signal<Void, NoError> in
|
||||
return .complete()
|
||||
}
|
||||
@@ -941,7 +941,7 @@ public final class ChannelMembersSearchContainerNode: SearchDisplayControllerCon
|
||||
peers[creator.id] = creator
|
||||
}
|
||||
peers[peer.id] = peer
|
||||
renderedParticipant = RenderedChannelParticipant(participant: .member(id: peer.id, invitedAt: 0, adminInfo: ChannelParticipantAdminInfo(rights: TelegramChatAdminRights(flags: .groupSpecific), promotedBy: creatorPeer?.id ?? context.account.peerId, canBeEditedByAccountPeer: creatorPeer?.id == context.account.peerId), banInfo: nil, rank: nil), peer: peer, peers: peers)
|
||||
renderedParticipant = RenderedChannelParticipant(participant: .member(id: peer.id, invitedAt: 0, adminInfo: ChannelParticipantAdminInfo(rights: TelegramChatAdminRights(rights: .groupSpecific), promotedBy: creatorPeer?.id ?? context.account.peerId, canBeEditedByAccountPeer: creatorPeer?.id == context.account.peerId), banInfo: nil, rank: nil), peer: peer, peers: peers)
|
||||
case .member:
|
||||
var peers: [PeerId: Peer] = [:]
|
||||
peers[peer.id] = peer
|
||||
|
||||
Reference in New Issue
Block a user