From aca6e5bf466735b0e9c9f9815ebf0c60332d0033 Mon Sep 17 00:00:00 2001 From: "Paul \"LeoNerd\" Evans" Date: Fri, 13 Nov 2015 17:27:25 +0000 Subject: [PATCH] Don't complain if /make_join response lacks 'prev_state' list (SYN-517) --- synapse/federation/federation_client.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/synapse/federation/federation_client.py b/synapse/federation/federation_client.py index d4f586fae..c6a8c1249 100644 --- a/synapse/federation/federation_client.py +++ b/synapse/federation/federation_client.py @@ -401,6 +401,12 @@ class FederationClient(FederationBase): pdu_dict["content"].update(content) + # The protoevent received over the JSON wire may not have all + # the required fields. Lets just gloss over that because + # there's some we never care about + if "prev_state" not in pdu_dict: + pdu_dict["prev_state"] = [] + defer.returnValue( (destination, self.event_from_pdu_json(pdu_dict)) )