[Fix] Legacy API Node Depth Parsing, description validation in Reaction.create (#402)

Co-authored-by: Tim Lorsbach <tim@lorsba.ch>
Reviewed-on: enviPath/enviPy#402
This commit is contained in:
2026-05-28 09:53:39 +12:00
parent c7c7e17e43
commit 1a9f1cf9af
2 changed files with 6 additions and 3 deletions

View File

@ -1891,7 +1891,7 @@ def add_pathway_node(request, package_uuid, pathway_uuid, n: Form[CreateNode]):
pw = Pathway.objects.get(package=p, uuid=pathway_uuid)
if n.nodeDepth is not None and n.nodeDepth.strip() != "":
node_depth = int(n.nodeDepth)
node_depth = int(float(n.nodeDepth))
else:
node_depth = -1