pszemraj commited on
Commit
4bd36bc
โ€ข
1 Parent(s): 3db06ee

๐Ÿšธ add fancy error

Browse files

Signed-off-by: peter szemraj <peterszemraj@gmail.com>

Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -82,10 +82,11 @@ def convert_PDF(
82
 
83
  html_error = f"""
84
  <div style="color: red; font-size: 20px; font-weight: bold;">
85
- File {file_path} is not a PDF file
86
  </div>
87
  """
88
  return "File is not a PDF file", html_error, None
 
89
  conversion_stats = convert_PDF_to_Text(
90
  file_path,
91
  ocr_model=ocr_model,
 
82
 
83
  html_error = f"""
84
  <div style="color: red; font-size: 20px; font-weight: bold;">
85
+ File {file_path} is not a PDF file. Please upload a PDF file.
86
  </div>
87
  """
88
  return "File is not a PDF file", html_error, None
89
+
90
  conversion_stats = convert_PDF_to_Text(
91
  file_path,
92
  ocr_model=ocr_model,