Skip to content

Commit

Permalink
fixed sensors_data empty check
Browse files Browse the repository at this point in the history
  • Loading branch information
Nik Sauer committed Jan 28, 2025
1 parent 5083afd commit 271be11
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/api/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ def post(self, request, *args, **kwargs):
# Record the time when the request was received
time_received = datetime.datetime.now(datetime.timezone.utc)

if sensors_data:
if sensors_data is None:
return JsonResponse({"status": "success, but no sensor data found"}, status=200)

try:
Expand Down

0 comments on commit 271be11

Please sign in to comment.