refac/fix: kb image upload handling

This commit is contained in:
Timothy Jaeryang Baek
2025-10-28 00:34:53 -07:00
parent e986488ab5
commit f524a6a8e7
3 changed files with 16 additions and 7 deletions
+4
View File
@@ -115,6 +115,10 @@ def process_uploaded_file(request, file, file_path, file_item, file_metadata, us
request.app.state.config.CONTENT_EXTRACTION_ENGINE == "external"
):
process_file(request, ProcessFileForm(file_id=file_item.id), user=user)
else:
raise Exception(
f"File type {file.content_type} is not supported for processing"
)
else:
log.info(
f"File type {file.content_type} is not provided, but trying to process anyway"