summary refs log tree commit diff
path: root/synapse/handlers/message.py
diff options
context:
space:
mode:
authorRichard van der Hoff <1389908+richvdh@users.noreply.github.com>2020-10-28 20:41:42 +0000
committerErik Johnston <erik@matrix.org>2020-10-30 15:24:10 +0000
commit90c900a8ff12cf330bb2010f13f3dfeb42930f41 (patch)
tree70035405751a623c34852dc091b7a420c04c7fe0 /synapse/handlers/message.py
parentTie together matches_user_in_member_list and get_users_in_room caches (#8676) (diff)
downloadsynapse-90c900a8ff12cf330bb2010f13f3dfeb42930f41.tar.xz
Merge pull request #8678 from matrix-org/rav/fix_frozen_events
Fix serialisation errors when using third-party event rules.
Diffstat (limited to 'synapse/handlers/message.py')
-rw-r--r--synapse/handlers/message.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/synapse/handlers/message.py b/synapse/handlers/message.py
index d6855c60ea..fb0a04e9a7 100644
--- a/synapse/handlers/message.py
+++ b/synapse/handlers/message.py
@@ -50,9 +50,8 @@ from synapse.replication.http.send_event import ReplicationSendEventRestServlet
 from synapse.storage.databases.main.events_worker import EventRedactBehaviour
 from synapse.storage.state import StateFilter
 from synapse.types import Requester, RoomAlias, StreamToken, UserID, create_requester
-from synapse.util import json_decoder
+from synapse.util import json_decoder, json_encoder
 from synapse.util.async_helpers import Linearizer
-from synapse.util.frozenutils import frozendict_json_encoder
 from synapse.util.metrics import measure_func
 from synapse.visibility import filter_events_for_client
 
@@ -928,7 +927,7 @@ class EventCreationHandler:
 
         # Ensure that we can round trip before trying to persist in db
         try:
-            dump = frozendict_json_encoder.encode(event.content)
+            dump = json_encoder.encode(event.content)
             json_decoder.decode(dump)
         except Exception:
             logger.exception("Failed to encode content: %r", event.content)