Skip to content
Snippets Groups Projects
Commit 3b2dfabd authored by Nils G.'s avatar Nils G.
Browse files

Correctly check the definition for length field

parent 636f13bc
No related branches found
No related tags found
No related merge requests found
......@@ -96,7 +96,7 @@ def submit():
if (not isinstance(inputs[key], str)) or (keytest != key):
return(FAIL(CODE_MISSING))
if input_definitions[key]["length"] and len(inputs[key]) > input_definitions[key]["length"]:
if "length" in input_definitions[key] and len(inputs[key]) > input_definitions[key]["length"]:
return(FAIL(CODE_MISSING))
inputs[key] = ''.join(c for c in inputs[key] if (c.isalnum() or c == " "))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment