Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -71,7 +71,7 @@ def generate_pdf(company_name):
|
|
| 71 |
# Check if file exists
|
| 72 |
if os.path.exists(pdf_file_path):
|
| 73 |
print(f"PDF successfully created at {pdf_file_path}")
|
| 74 |
-
return pdf_file_path
|
| 75 |
else:
|
| 76 |
return "Error: PDF not generated."
|
| 77 |
|
|
@@ -106,3 +106,4 @@ with gr.Blocks() as app:
|
|
| 106 |
|
| 107 |
# Launch the app
|
| 108 |
app.launch(share=True)
|
|
|
|
|
|
| 71 |
# Check if file exists
|
| 72 |
if os.path.exists(pdf_file_path):
|
| 73 |
print(f"PDF successfully created at {pdf_file_path}")
|
| 74 |
+
return pdf_file_path # Returning the correct file path for Gradio to download
|
| 75 |
else:
|
| 76 |
return "Error: PDF not generated."
|
| 77 |
|
|
|
|
| 106 |
|
| 107 |
# Launch the app
|
| 108 |
app.launch(share=True)
|
| 109 |
+
|