Fix broken registration: missing cur and wronge exc
This commit is contained in:
parent
c04b5a6db0
commit
2deff86e13
2 changed files with 2 additions and 1 deletions
|
@ -1061,6 +1061,7 @@ class PDBUserMixin:
|
||||||
|
|
||||||
(qmarks, bindings) = helpers.binding_filler(constants.SQL_USER_COLUMNS, data)
|
(qmarks, bindings) = helpers.binding_filler(constants.SQL_USER_COLUMNS, data)
|
||||||
query = 'INSERT INTO users VALUES(%s)' % qmarks
|
query = 'INSERT INTO users VALUES(%s)' % qmarks
|
||||||
|
cur = self.sql.cursor()
|
||||||
cur.execute(query, bindings)
|
cur.execute(query, bindings)
|
||||||
|
|
||||||
if commit:
|
if commit:
|
||||||
|
|
|
@ -245,7 +245,7 @@ def post_register():
|
||||||
|
|
||||||
try:
|
try:
|
||||||
user = P.register_user(username, password_1)
|
user = P.register_user(username, password_1)
|
||||||
except EtiquetteException as e:
|
except exceptions.EtiquetteException as e:
|
||||||
response = {
|
response = {
|
||||||
'error_type': e.error_type,
|
'error_type': e.error_type,
|
||||||
'error_message': e.error_message,
|
'error_message': e.error_message,
|
||||||
|
|
Loading…
Reference in a new issue