fix: restore ValueError handling in WorkflowByIdApi for improved error reporting
Signed-off-by: -LAN- <laipz8200@outlook.com>
This commit is contained in:
parent
5e7890f36f
commit
c9e455ad14
@ -602,12 +602,12 @@ class WorkflowByIdApi(Resource):
|
||||
)
|
||||
# Commit the transaction in the controller
|
||||
session.commit()
|
||||
except ValueError as e:
|
||||
raise NotFound(str(e))
|
||||
except WorkflowInUseError as e:
|
||||
abort(400, description=str(e))
|
||||
except DraftWorkflowDeletionError as e:
|
||||
abort(400, description=str(e))
|
||||
except ValueError as e:
|
||||
raise NotFound(str(e))
|
||||
|
||||
return None, 204
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user