diff options
author | Erik Johnston <erikj@jki.re> | 2018-06-22 14:47:43 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-06-22 14:47:43 +0100 |
commit | b4a5d767a94f1680d07edfd583aae54ce422573e (patch) | |
tree | 43e9d8da6aeb2f1acade68c5733faa17285cf1a0 /synapse/federation | |
parent | Merge pull request #3427 from matrix-org/erikj/remove_filters (diff) | |
parent | simplify get_persisted_pdu (diff) | |
download | synapse-b4a5d767a94f1680d07edfd583aae54ce422573e.tar.xz |
Merge pull request #3428 from matrix-org/erikj/persisted_pdu
Simplify get_persisted_pdu
Diffstat (limited to 'synapse/federation')
-rw-r--r-- | synapse/federation/federation_server.py | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/synapse/federation/federation_server.py b/synapse/federation/federation_server.py index 2d420a58a2..d4dd967c60 100644 --- a/synapse/federation/federation_server.py +++ b/synapse/federation/federation_server.py @@ -277,7 +277,7 @@ class FederationServer(FederationBase): @defer.inlineCallbacks @log_function def on_pdu_request(self, origin, event_id): - pdu = yield self._get_persisted_pdu(origin, event_id) + pdu = yield self.handler.get_persisted_pdu(origin, event_id) if pdu: defer.returnValue( @@ -470,17 +470,6 @@ class FederationServer(FederationBase): ts_now_ms = self._clock.time_msec() return self.store.get_user_id_for_open_id_token(token, ts_now_ms) - @log_function - def _get_persisted_pdu(self, origin, event_id, do_auth=True): - """ Get a PDU from the database with given origin and id. - - Returns: - Deferred: Results in a `Pdu`. - """ - return self.handler.get_persisted_pdu( - origin, event_id, do_auth=do_auth - ) - def _transaction_from_pdus(self, pdu_list): """Returns a new Transaction containing the given PDUs suitable for transmission. |