feat(dl): Add support for services that do not support subtitle downloads

This commit is contained in:
Andy
2025-08-05 20:22:08 +00:00
parent 1bd63ddc91
commit 948ef30de7
2 changed files with 8 additions and 1 deletions

View File

@@ -541,7 +541,12 @@ class dl:
events.subscribe(events.Types.TRACK_REPACKED, service.on_track_repacked)
events.subscribe(events.Types.TRACK_MULTIPLEX, service.on_track_multiplex)
if no_subs:
if hasattr(service, 'NO_SUBTITLES') and service.NO_SUBTITLES:
console.log("Skipping subtitles - service does not support subtitle downloads")
no_subs = True
s_lang = None
title.tracks.subtitles = []
elif no_subs:
console.log("Skipped subtitles as --no-subs was used...")
s_lang = None
title.tracks.subtitles = []
@@ -906,6 +911,7 @@ class dl:
while (
not title.tracks.subtitles
and not no_subs
and not (hasattr(service, 'NO_SUBTITLES') and service.NO_SUBTITLES)
and not video_only
and len(title.tracks.videos) > video_track_n
and any(