summary refs log tree commit diff
path: root/synapse/rest/register.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2014-08-24 12:17:59 +0100
committerErik Johnston <erik@matrix.org>2014-08-24 12:17:59 +0100
commit4521c2d277fd56e505f28ebf372d204c52a4f979 (patch)
tree73d30c9aaa8c99a7f6ba18eb3f23b5521bb3d1b2 /synapse/rest/register.py
parentoops (diff)
parentFor the content repo, don't just use homeserver.hostname as that might not in... (diff)
downloadsynapse-4521c2d277fd56e505f28ebf372d204c52a4f979.tar.xz
Merge branch 'hotfixes-0.0.1' of github.com:matrix-org/synapse
Diffstat (limited to 'synapse/rest/register.py')
-rw-r--r--synapse/rest/register.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/rest/register.py b/synapse/rest/register.py
index eb457562b9..f17ec11cf4 100644
--- a/synapse/rest/register.py
+++ b/synapse/rest/register.py
@@ -33,10 +33,10 @@ class RegisterRestServlet(RestServlet):
         try:
             register_json = json.loads(request.content.read())
             if "password" in register_json:
-                password = register_json["password"]
+                password = register_json["password"].encode("utf-8")
 
             if type(register_json["user_id"]) == unicode:
-                desired_user_id = register_json["user_id"]
+                desired_user_id = register_json["user_id"].encode("utf-8")
                 if urllib.quote(desired_user_id) != desired_user_id:
                     raise SynapseError(
                         400,