summary refs log tree commit diff
path: root/synapse
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2016-07-05 17:34:25 +0100
committerErik Johnston <erik@matrix.org>2016-07-05 17:34:25 +0100
commit4adf93e0f743338c929860a1384beabeae9fded8 (patch)
tree12e11ca3db22ba92e919dcc4f3d199d342341bd2 /synapse
parentAdd an admin option to shared secret registration (diff)
downloadsynapse-4adf93e0f743338c929860a1384beabeae9fded8.tar.xz
Fix for postgres
Diffstat (limited to '')
-rw-r--r--synapse/storage/registration.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/registration.py b/synapse/storage/registration.py
index 4999175ddb..232dcfd9eb 100644
--- a/synapse/storage/registration.py
+++ b/synapse/storage/registration.py
@@ -147,7 +147,7 @@ class RegistrationStore(SQLBaseStore):
                         "upgrade_ts": now,
                         "is_guest": 1 if make_guest else 0,
                         "appservice_id": appservice_id,
-                        "admin": admin,
+                        "admin": 1 if admin else 0,
                     }
                 )
             else:
@@ -160,7 +160,7 @@ class RegistrationStore(SQLBaseStore):
                         "creation_ts": now,
                         "is_guest": 1 if make_guest else 0,
                         "appservice_id": appservice_id,
-                        "admin": admin,
+                        "admin": 1 if admin else 0,
                     }
                 )
         except self.database_engine.module.IntegrityError: