mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 01:20:12 +00:00
Restore permissions to creator and display them as owners in the list (#4369)
* restore permissions to creator and display them as owners in the list * improved the code to use actually 5 roles in the app to distinguish a real creator from an owner
This commit is contained in:
+2
-1
@@ -84,7 +84,8 @@ class RoomRolesAndPermissionsScreenViewModel: RoomRolesAndPermissionsScreenViewM
|
||||
// MARK: - Members
|
||||
|
||||
private func updateMembers(_ members: [RoomMemberProxyProtocol]) {
|
||||
state.administratorCount = members.filter { $0.role == .administrator && $0.isActive }.count
|
||||
// TODO: Will probably be changed when we implement the owners list
|
||||
state.administratorCount = members.filter { $0.role.isAdminOrHigher && $0.isActive }.count
|
||||
state.moderatorCount = members.filter { $0.role == .moderator && $0.isActive }.count
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user