Skip to content

Commit

Permalink
precommit
Browse files Browse the repository at this point in the history
  • Loading branch information
Krrupa committed Mar 28, 2024
1 parent 60ab3c6 commit 74ca318
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions app/router/form.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,14 @@ def is_student_attribute_empty(field, student_data):
or student_data[key] is None
for key in parent_keys
)

if key == "grade":
return "grade_id" not in student_data or student_data["grade_id"] is None or student_data["grade_id"] == ""

return (
"grade_id" not in student_data
or student_data["grade_id"] is None
or student_data["grade_id"] == ""
)

return key in STUDENT_QUERY_PARAMS and (
key not in student_data or student_data[key] is None or student_data[key] == ""
)
Expand Down

0 comments on commit 74ca318

Please sign in to comment.