Also ignore youtube playlists

main
Bob Mottram 2022-03-08 16:09:11 +00:00
parent 8070d2a276
commit 7ce38ceef8
1 changed files with 2 additions and 2 deletions

View File

@ -55,7 +55,7 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
url = content.split('"' + video_site)[1]
if '"' in url:
url = url.split('"')[0]
if '/channel/' not in url:
if '/channel/' not in url and '/playlist' not in url:
url = url.replace('/watch?v=', '/embed/')
if '&' in url:
url = url.split('&')[0]
@ -74,7 +74,7 @@ def _add_embedded_video_from_sites(translate: {}, content: str,
url = content.split('"' + video_site)[1]
if '"' in url:
url = url.split('"')[0]
if '/channel/' not in url:
if '/channel/' not in url and '/playlist' not in url:
url = 'embed/' + url
if '&' in url:
url = url.split('&')[0]