diff options
author | Erik Johnston <erik@matrix.org> | 2015-04-15 10:24:24 +0100 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2015-04-15 10:24:24 +0100 |
commit | ded41289655d083194061678c24d3e5551e64a7d (patch) | |
tree | c64791657b481ec301120a85bccfd96a1503a02d /synapse | |
parent | Add missing yield in storage func (diff) | |
download | synapse-ded41289655d083194061678c24d3e5551e64a7d.tar.xz |
Use True for True rather than 1
Diffstat (limited to '')
-rw-r--r-- | synapse/storage/events.py | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/synapse/storage/events.py b/synapse/storage/events.py index 9fe2effb4b..0373d152b2 100644 --- a/synapse/storage/events.py +++ b/synapse/storage/events.py @@ -269,13 +269,15 @@ class EventsStore(SQLBaseStore): "INSERT INTO events" " (stream_ordering, topological_ordering, event_id, type," " room_id, content, processed, outlier, depth)" - " VALUES (%s,?,?,?,?,?,?,?,?)" - ) % (stream_ordering,) + " VALUES (?,?,?,?,?,?,?,?,?)" + ) txn.execute( sql, - (event.depth, event.event_id, event.type, event.room_id, - content, True, outlier, event.depth) + ( + stream_ordering, event.depth, event.event_id, event.type, + event.room_id, content, True, outlier, event.depth + ) ) if context.rejected: @@ -321,7 +323,7 @@ class EventsStore(SQLBaseStore): "event_id": event.event_id, "prev_event_id": e_id, "room_id": event.room_id, - "is_state": 1, + "is_state": True, }, ) |