diff --git a/DEPLOY.md b/DEPLOY.md index 1bfae28..1d1fe48 100644 --- a/DEPLOY.md +++ b/DEPLOY.md @@ -1,5 +1,5 @@ -docker build -t 192.168.2.212:3000/tigeren/metube:1.3 . +docker build -t 192.168.2.212:3000/tigeren/metube:1.4 . -docker push 192.168.2.212:3000/tigeren/metube:1.3 +docker push 192.168.2.212:3000/tigeren/metube:1.4 docker compose up -d --build --force-recreate \ No newline at end of file diff --git a/app/ytdl.py b/app/ytdl.py index 30486d4..5bd5ee7 100644 --- a/app/ytdl.py +++ b/app/ytdl.py @@ -563,10 +563,12 @@ class DownloadQueue: parsed_url = urlparse(v.info.url) v.info.website = parsed_url.netloc - if v.info.filename: + # Use getattr with default to safely check for filename attribute + filename = getattr(v.info, 'filename', None) + if filename: dldirectory, _ = self.__calc_download_path(v.info.quality, v.info.format, v.info.folder) if dldirectory: - filepath = os.path.join(dldirectory, v.info.filename) + filepath = os.path.join(dldirectory, filename) v.info.file_exists = os.path.exists(filepath) else: v.info.file_exists = False