mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-10-07 09:18:23 -04:00
Add a timeout param to get_event
This commit is contained in:
parent
6837c5edab
commit
5b1631a4a9
4 changed files with 25 additions and 16 deletions
|
@ -50,7 +50,7 @@ class TransportLayerClient(object):
|
|||
)
|
||||
|
||||
@log_function
|
||||
def get_event(self, destination, event_id):
|
||||
def get_event(self, destination, event_id, timeout=None):
|
||||
""" Requests the pdu with give id and origin from the given server.
|
||||
|
||||
Args:
|
||||
|
@ -65,7 +65,7 @@ class TransportLayerClient(object):
|
|||
destination, event_id)
|
||||
|
||||
path = PREFIX + "/event/%s/" % (event_id, )
|
||||
return self.client.get_json(destination, path=path)
|
||||
return self.client.get_json(destination, path=path, timeout=timeout)
|
||||
|
||||
@log_function
|
||||
def backfill(self, destination, room_id, event_tuples, limit):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue