From 5cc10367b2ac4b1315a7bdbb6ee77fc6bbb82439 Mon Sep 17 00:00:00 2001 From: profitroll Date: Fri, 23 Jun 2023 11:30:18 +0200 Subject: [PATCH] Typo fixed --- extensions/videos.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/extensions/videos.py b/extensions/videos.py index 88aa50c..91ebffd 100644 --- a/extensions/videos.py +++ b/extensions/videos.py @@ -159,8 +159,8 @@ async def video_move( raise AlbumNameNotFoundError(album) if Path( - f"data"/users/{current_user.user}/albums/{album}/{video['filename']}" - ).exists(): + f"data/users/{current_user.user}/albums/{album}/{video['filename']}" + ).exists(): base_name = video["filename"].split(".")[:-1] extension = video["filename"].split(".")[-1] filename = ( @@ -181,7 +181,9 @@ async def video_move( ) move( - Path(f"data/users/{current_user.user}/albums/{video['album']}/{video['filename']}"), + Path( + f"data/users/{current_user.user}/albums/{video['album']}/{video['filename']}" + ), Path(f"data/users/{current_user.user}/albums/{album}/{filename}"), ) @@ -252,7 +254,9 @@ async def video_delete( album = col_albums.find_one({"name": video["album"]}) remove( - Path(f"data/users/{current_user.user}/albums/{video['album']}/{video['filename']}") + Path( + f"data/users/{current_user.user}/albums/{video['album']}/{video['filename']}" + ) ) return Response(status_code=HTTP_204_NO_CONTENT)