This commit is contained in:
Marek Lenczewski
2026-04-06 10:42:29 +02:00
parent b6635a107d
commit 8ecef00d0a
14 changed files with 128 additions and 61 deletions

View File

@@ -104,7 +104,8 @@ def download_file(video_id: int, db: Session = Depends(get_db)):
path = Path(video.file_path)
if not path.exists():
raise HTTPException(status_code=404, detail="Videodatei nicht gefunden")
video_service.update_file_path(db, video_id, None)
raise HTTPException(status_code=404, detail="Video noch nicht heruntergeladen")
return FileResponse(path, media_type="video/mp4", filename=f"{video.title}.mp4")