diff options
author | Erik Johnston <erik@matrix.org> | 2014-12-10 10:06:12 +0000 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2014-12-10 11:37:47 +0000 |
commit | 95aa903ffa77effcbca2a510744c3c3fa9b46ed3 (patch) | |
tree | da5d6eeec5da95549d19e97a072ce575c0fadf41 /synapse/events/builder.py | |
parent | This is to test jenkins (diff) | |
download | synapse-95aa903ffa77effcbca2a510744c3c3fa9b46ed3.tar.xz |
Try and figure out how and why signatures are being changed.
Diffstat (limited to 'synapse/events/builder.py')
-rw-r--r-- | synapse/events/builder.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/synapse/events/builder.py b/synapse/events/builder.py index 127b8fa904..642264e9f3 100644 --- a/synapse/events/builder.py +++ b/synapse/events/builder.py @@ -54,10 +54,9 @@ class EventBuilderFactory(object): return e_id.to_string() def new(self, key_values={}): - if "event_id" not in key_values: - key_values["event_id"] = self.create_event_id() + key_values["event_id"] = self.create_event_id() - time_now = self.clock.time_msec() + time_now = int(self.clock.time_msec()) key_values.setdefault("origin", self.hostname) key_values.setdefault("origin_server_ts", time_now) @@ -66,4 +65,6 @@ class EventBuilderFactory(object): age = key_values["unsigned"].pop("age", 0) key_values["unsigned"].setdefault("age_ts", time_now - age) + key_values["signatures"] = {} + return EventBuilder(key_values=key_values,) |