Skip to content
Snippets Groups Projects
Commit dcadfbbd authored by Erik Johnston's avatar Erik Johnston
Browse files

Don't strip out null's in serialized events, as that is not need anymore and...

Don't strip out null's in serialized events, as that is not need anymore and it's not in the spec (yet)
parent 69ddec65
No related branches found
No related tags found
No related merge requests found
...@@ -22,7 +22,8 @@ def serialize_event(hs, e): ...@@ -22,7 +22,8 @@ def serialize_event(hs, e):
if not isinstance(e, SynapseEvent): if not isinstance(e, SynapseEvent):
return e return e
d = {k: v for k, v in e.get_dict().items() if v is not None} # Should this strip out None's?
d = {k: v for k, v in e.get_dict().items()}
if "age_ts" in d: if "age_ts" in d:
d["age"] = int(hs.get_clock().time_msec()) - d["age_ts"] d["age"] = int(hs.get_clock().time_msec()) - d["age_ts"]
del d["age_ts"] del d["age_ts"]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment