summary refs log tree commit diff
path: root/synapse/api/events/validator.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2014-11-11 10:31:47 +0000
committerErik Johnston <erik@matrix.org>2014-11-11 10:31:47 +0000
commit2cdff00788a4d6075466dcc638fbef90395c1017 (patch)
treef81012d630ecf3de1ee2e9f49b2c883818ce5813 /synapse/api/events/validator.py
parentFix rest.test_rooms (diff)
downloadsynapse-2cdff00788a4d6075466dcc638fbef90395c1017.tar.xz
Fix typo in validator
Diffstat (limited to 'synapse/api/events/validator.py')
-rw-r--r--synapse/api/events/validator.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/synapse/api/events/validator.py b/synapse/api/events/validator.py
index 59b486d6d7..2d4f2a3aa7 100644
--- a/synapse/api/events/validator.py
+++ b/synapse/api/events/validator.py
@@ -70,12 +70,18 @@ class EventValidator(object):
 
                 if type(content[key]) == dict:
                     # we must go deeper
-                    msg = self._check_json(content[key], template[key])
+                    msg = self._check_json_template(
+                        content[key],
+                        template[key]
+                    )
                     if msg:
                         return msg
                 elif type(content[key]) == list:
                     # make sure each item type in content matches the template
                     for entry in content[key]:
-                        msg = self._check_json(entry, template[key][0])
+                        msg = self._check_json_template(
+                            entry,
+                            template[key][0]
+                        )
                         if msg:
                             return msg
\ No newline at end of file