mirror of
https://github.com/element-hq/synapse
synced 2024-08-20 17:50:21 +00:00
Add missing None check
This commit is contained in:
parent
3cb1799347
commit
7b62d0bc70
1 changed files with 6 additions and 5 deletions
|
@ -232,11 +232,12 @@ class RoomMemberHandler(BaseHandler):
|
||||||
errcode=Codes.BAD_STATE
|
errcode=Codes.BAD_STATE
|
||||||
)
|
)
|
||||||
|
|
||||||
same_content = content == old_state.content
|
if old_state:
|
||||||
same_membership = old_membership == effective_membership_state
|
same_content = content == old_state.content
|
||||||
same_sender = requester.user.to_string() == old_state.sender
|
same_membership = old_membership == effective_membership_state
|
||||||
if same_sender and same_membership and same_content:
|
same_sender = requester.user.to_string() == old_state.sender
|
||||||
defer.returnValue(old_state)
|
if same_sender and same_membership and same_content:
|
||||||
|
defer.returnValue(old_state)
|
||||||
|
|
||||||
is_host_in_room = yield self._is_host_in_room(current_state_ids)
|
is_host_in_room = yield self._is_host_in_room(current_state_ids)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue