mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 12:07:55 +00:00
Update the "remove avatar" logic in edit room details (#1032)
* Refactor remove avatar logic * Add test
This commit is contained in:
@@ -66,11 +66,8 @@ class RoomDetailsEditScreenViewModel: RoomDetailsEditScreenViewModelType, RoomDe
|
||||
case .displayMediaPicker:
|
||||
actionsSubject.send(.displayMediaPicker)
|
||||
case .removeImage:
|
||||
if state.localMedia != nil {
|
||||
state.localMedia = nil
|
||||
} else {
|
||||
state.avatarURL = nil
|
||||
}
|
||||
state.avatarURL = nil
|
||||
state.localMedia = nil
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user