From 9c0891eb7daefc54aa304a41b7c402b691007c85 Mon Sep 17 00:00:00 2001 From: Rio Liu Date: Mon, 6 Sep 2021 21:05:52 -0400 Subject: [PATCH] handle None for required position --- ceod/api/positions.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ceod/api/positions.py b/ceod/api/positions.py index 9d9f4c4..93b757f 100644 --- a/ceod/api/positions.py +++ b/ceod/api/positions.py @@ -36,7 +36,7 @@ def update_positions(): }, 400 for position in required: - if position not in body: + if not body.get(position): return { 'error': f'missing required position: {position}' }, 400