mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-03-18 20:29:10 +03:00
Fix demote yourself issue
This commit is contained in:
parent
959be3a23d
commit
3430a8f3ea
1 changed files with 1 additions and 1 deletions
|
@ -159,7 +159,7 @@ class RoomMemberProfileViewModel @AssistedInject constructor(@Assisted private v
|
|||
val myPowerLevel = PowerLevelsHelper(currentPowerLevelsContent).getUserPowerLevelValue(session.myUserId)
|
||||
if (action.askForValidation && action.newValue >= myPowerLevel) {
|
||||
_viewEvents.post(RoomMemberProfileViewEvents.ShowPowerLevelValidation(action.previousValue, action.newValue))
|
||||
} else if (state.isMine) {
|
||||
} else if (action.askForValidation && state.isMine) {
|
||||
_viewEvents.post(RoomMemberProfileViewEvents.ShowPowerLevelDemoteWarning(action.previousValue, action.newValue))
|
||||
} else {
|
||||
currentPowerLevelsContent.users[state.userId] = action.newValue
|
||||
|
|
Loading…
Add table
Reference in a new issue