fix 500 error

pull/226/head
Aevann 2024-05-05 12:22:23 +03:00
parent 8b334e1d4e
commit 34e0a817a3
1 changed files with 1 additions and 2 deletions

View File

@ -53,8 +53,7 @@ def submit_art_post(v):
hole = request.values.get('hole', '').lower().strip()
if hole:
hole = g.db.get(Hole, hole)
if not hole:
if not g.db.get(Hole, hole):
abort(404, "Hole not found!")
else:
hole = None