Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -320,7 +320,7 @@ def create_interface():
|
|
320 |
return "Please enter a YouTube URL", gr.File(visible=False), gr.Button(visible=False), None
|
321 |
|
322 |
# Set cookies path if provided
|
323 |
-
|
324 |
|
325 |
# First get video info and store it
|
326 |
video_info, info_message = downloader.get_video_info(url,cookiefile=cookiefile)
|
|
|
320 |
return "Please enter a YouTube URL", gr.File(visible=False), gr.Button(visible=False), None
|
321 |
|
322 |
# Set cookies path if provided
|
323 |
+
cookiefile = cookies_path if cookies_path and os.path.exists(cookies_path) else None
|
324 |
|
325 |
# First get video info and store it
|
326 |
video_info, info_message = downloader.get_video_info(url,cookiefile=cookiefile)
|