From 69ddec65895d33a25dbaa5991462e32442dbe6e5 Mon Sep 17 00:00:00 2001 From: Erik Johnston Date: Thu, 25 Sep 2014 16:49:02 +0100 Subject: [PATCH] Don't strip of False values from events when serializing --- synapse/api/events/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/synapse/api/events/__init__.py b/synapse/api/events/__init__.py index 0ceb703c74..db6dff5762 100644 --- a/synapse/api/events/__init__.py +++ b/synapse/api/events/__init__.py @@ -22,7 +22,7 @@ def serialize_event(hs, e): if not isinstance(e, SynapseEvent): return e - d = {k: v for k, v in e.get_dict().items() if v is not None or v is not False} + d = {k: v for k, v in e.get_dict().items() if v is not None} if "age_ts" in d: d["age"] = int(hs.get_clock().time_msec()) - d["age_ts"] del d["age_ts"]