summary refs log tree commit diff
path: root/synapse/handlers/auth.py
diff options
context:
space:
mode:
authorAmber Brown <hawkowl@atleastfornow.net>2018-06-28 14:49:57 +0100
committerGitHub <noreply@github.com>2018-06-28 14:49:57 +0100
commit6350bf925e8651f2fae70a1e7eb7182e9161c34a (patch)
tree35e766fcb2dabcd1e8978c417709b353d5fdf4bc /synapse/handlers/auth.py
parentRevert "Revert "Try to not use as much CPU in the StreamChangeCache"" (#3454) (diff)
downloadsynapse-6350bf925e8651f2fae70a1e7eb7182e9161c34a.tar.xz
Attempt to be more performant on PyPy (#3462)
Diffstat (limited to 'synapse/handlers/auth.py')
-rw-r--r--synapse/handlers/auth.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/synapse/handlers/auth.py b/synapse/handlers/auth.py
index a131b7f73f..cbef1f2770 100644
--- a/synapse/handlers/auth.py
+++ b/synapse/handlers/auth.py
@@ -16,6 +16,8 @@
 
 from twisted.internet import defer, threads
 
+from canonicaljson import json
+
 from ._base import BaseHandler
 from synapse.api.constants import LoginType
 from synapse.api.errors import (
@@ -32,7 +34,6 @@ from twisted.web.client import PartialDownloadError
 import logging
 import bcrypt
 import pymacaroons
-import simplejson
 import attr
 
 import synapse.util.stringutils as stringutils
@@ -403,7 +404,7 @@ class AuthHandler(BaseHandler):
         except PartialDownloadError as pde:
             # Twisted is silly
             data = pde.response
-            resp_body = simplejson.loads(data)
+            resp_body = json.loads(data)
 
         if 'success' in resp_body:
             # Note that we do NOT check the hostname here: we explicitly