Compare commits

..
2 Commits
Author SHA1 Message Date
retoor 983d4d668f Automatic upload folder creation if not exists.
RUpload build / Build (push) Successful in 1m2s
2024-11-26 06:31:32 +01:00
retoor 2f6ecfe06d Made upload path dynamic. 2024-11-26 06:31:32 +01:00
+2 -1
View File
@@ -287,11 +287,12 @@ def create_app(
max_file_size=max_file_size,
upload_folder_quota=upload_folder_quota,
)
pathlib.Path(upload_path).mkdir(parents=True, exist_ok=True)
app.add_routes(
[
web.get("/", handle_index),
web.post("/upload", handle_upload),
web.static("/uploads", "uploads"),
web.static("/uploads", upload_path),
]
)
return app