fix(chalice): fixed reset&update password at the same time (#1790)
This commit is contained in:
parent
b5375df6e1
commit
1fb852590c
2 changed files with 4 additions and 0 deletions
|
|
@ -127,6 +127,8 @@ def update(tenant_id, user_id, changes, output=True):
|
|||
sub_query_bauth.append("changed_at = timezone('utc'::text, now())")
|
||||
sub_query_bauth.append("change_pwd_expire_at = NULL")
|
||||
sub_query_bauth.append("change_pwd_token = NULL")
|
||||
sub_query_bauth.append("invitation_token = NULL")
|
||||
sub_query_bauth.append("invited_at = NULL")
|
||||
else:
|
||||
sub_query_bauth.append(f"{helper.key_to_snake_case(key)} = %({key})s")
|
||||
else:
|
||||
|
|
|
|||
|
|
@ -152,6 +152,8 @@ def update(tenant_id, user_id, changes, output=True):
|
|||
sub_query_bauth.append("changed_at = timezone('utc'::text, now())")
|
||||
sub_query_bauth.append("change_pwd_expire_at = NULL")
|
||||
sub_query_bauth.append("change_pwd_token = NULL")
|
||||
sub_query_bauth.append("invitation_token = NULL")
|
||||
sub_query_bauth.append("invited_at = NULL")
|
||||
else:
|
||||
sub_query_bauth.append(f"{helper.key_to_snake_case(key)} = %({key})s")
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue