Spaces:
Running
Running
Jatin Mehra
commited on
Commit
·
58dea7f
1
Parent(s):
3ab6ad2
Redirect home route to static index.html
Browse files
app.py
CHANGED
|
@@ -141,7 +141,8 @@ app.mount("/static", StaticFiles(directory="static"), name="static")
|
|
| 141 |
# Route for the home page
|
| 142 |
@app.get("/")
|
| 143 |
async def read_root():
|
| 144 |
-
|
|
|
|
| 145 |
|
| 146 |
# Route to upload a PDF file
|
| 147 |
@app.post("/upload-pdf")
|
|
|
|
| 141 |
# Route for the home page
|
| 142 |
@app.get("/")
|
| 143 |
async def read_root():
|
| 144 |
+
from fastapi.responses import RedirectResponse
|
| 145 |
+
return RedirectResponse(url="/static/index.html")
|
| 146 |
|
| 147 |
# Route to upload a PDF file
|
| 148 |
@app.post("/upload-pdf")
|