summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-10-16 14:46:32 +0100
committerErik Johnston <erik@matrix.org>2015-10-16 14:46:32 +0100
commit12122bfc36d26e0042ed89947072a82dcb3de0e2 (patch)
tree4f2499335cba1c83487bc21e9b533d8f8b57828a /synapse
parentExplicitly check for Sqlite3Engine (diff)
parentMerge pull request #308 from matrix-org/markjh/v2_filter_encoding (diff)
downloadsynapse-12122bfc36d26e0042ed89947072a82dcb3de0e2.tar.xz
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/search
Diffstat (limited to 'synapse')
-rw-r--r--synapse/storage/filtering.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/filtering.py b/synapse/storage/filtering.py
index 8800116570..700da8d8c3 100644
--- a/synapse/storage/filtering.py
+++ b/synapse/storage/filtering.py
@@ -34,10 +34,10 @@ class FilteringStore(SQLBaseStore):
             desc="get_user_filter",
         )
 
-        defer.returnValue(json.loads(def_json))
+        defer.returnValue(json.loads(def_json.decode("utf-8")))
 
     def add_user_filter(self, user_localpart, user_filter):
-        def_json = json.dumps(user_filter)
+        def_json = json.dumps(user_filter).encode("utf-8")
 
         # Need an atomic transaction to SELECT the maximal ID so far then
         # INSERT a new one