diff options
author | Hubert Chathi <hubert@uhoreg.ca> | 2019-08-01 16:31:40 -0400 |
---|---|---|
committer | Hubert Chathi <hubert@uhoreg.ca> | 2019-08-01 16:31:40 -0400 |
commit | 336c546d6af5e85d830b6fe7cdc5445f92060b8a (patch) | |
tree | 58a4794f7bcabf8c72013365d185f8099666d630 /synapse/events/third_party_rules.py | |
parent | Merge branch 'cross-signing_hidden' into cross-signing_keys (diff) | |
parent | don't need to return the hidden column any more (diff) | |
download | synapse-336c546d6af5e85d830b6fe7cdc5445f92060b8a.tar.xz |
Merge branch 'cross-signing_hidden' into cross-signing_keys
Diffstat (limited to 'synapse/events/third_party_rules.py')
-rw-r--r-- | synapse/events/third_party_rules.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/synapse/events/third_party_rules.py b/synapse/events/third_party_rules.py index 8f5d95696b..714a9b1579 100644 --- a/synapse/events/third_party_rules.py +++ b/synapse/events/third_party_rules.py @@ -51,7 +51,7 @@ class ThirdPartyEventRules(object): defer.Deferred[bool]: True if the event should be allowed, False if not. """ if self.third_party_rules is None: - defer.returnValue(True) + return True prev_state_ids = yield context.get_prev_state_ids(self.store) @@ -61,7 +61,7 @@ class ThirdPartyEventRules(object): state_events[key] = yield self.store.get_event(event_id, allow_none=True) ret = yield self.third_party_rules.check_event_allowed(event, state_events) - defer.returnValue(ret) + return ret @defer.inlineCallbacks def on_create_room(self, requester, config, is_requester_admin): @@ -98,7 +98,7 @@ class ThirdPartyEventRules(object): """ if self.third_party_rules is None: - defer.returnValue(True) + return True state_ids = yield self.store.get_filtered_current_state_ids(room_id) room_state_events = yield self.store.get_events(state_ids.values()) @@ -110,4 +110,4 @@ class ThirdPartyEventRules(object): ret = yield self.third_party_rules.check_threepid_can_be_invited( medium, address, state_events ) - defer.returnValue(ret) + return ret |