fix admin path and rollback on exception. w/ jlantz and elizabeth

This commit is contained in:
burnettk 2023-09-22 16:51:36 -04:00
parent 7cbff0cdf2
commit 0c4761ac20
No known key found for this signature in database
2 changed files with 2 additions and 1 deletions

View File

@ -75,4 +75,4 @@ def authentication_callback(
verify_token(request.args.get("token"), force_run=True)
response = request.args["response"]
SecretService.update_secret(f"{service}/{auth_method}", response, g.user.id, create_if_not_exists=True)
return redirect(f"{current_app.config['SPIFFWORKFLOW_BACKEND_URL_FOR_FRONTEND']}/admin/configuration")
return redirect(f"{current_app.config['SPIFFWORKFLOW_BACKEND_URL_FOR_FRONTEND']}/configuration")

View File

@ -40,6 +40,7 @@ class SecretService:
try:
db.session.commit()
except Exception as e:
db.session.rollback()
raise ApiError(
error_code="create_secret_error",
message=(