From 6bc0eb86d5b140ad437a11105cf7eb27f74e5ce1 Mon Sep 17 00:00:00 2001 From: Scott Idem Date: Thu, 19 Oct 2023 12:06:47 -0400 Subject: [PATCH] Minor wording change --- app/routers/event_file.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/routers/event_file.py b/app/routers/event_file.py index eebbda9..f6a5fe3 100644 --- a/app/routers/event_file.py +++ b/app/routers/event_file.py @@ -268,6 +268,10 @@ async def download_event_file( dir_path = event_file_obj.hosted_file.directory_path subdir_path = event_file_obj.hosted_file.subdirectory_path hash_sha256 = event_file_obj.hosted_file.hash_sha256 + if not hash_sha256: + log.error(f'The hash_sha256 value was not found in the database record. Event File ID: {event_file_id}') + return mk_resp(data=None, status_code=404, response=commons.response, status_message=f'The hash_sha256 value was not found in the database record. Event File ID: {event_file_id}') # Not Found + hash_filename = hash_sha256+'.file' if subdir_path: