hotfix crunchyroll audio no hardsub playlist

This commit is contained in:
stratumadev 2025-10-14 16:25:13 +02:00
parent d44189bdde
commit 9cec96a4b3

View file

@ -1954,6 +1954,14 @@ export default class Crunchy implements ServiceClass {
}
return s.hardsub_lang == options.hslang;
});
if (astreams.length < 1) {
console.warn('No audio streams found, using video audio streams instead');
astreams = vstreams;
}
if (vstreams.length < 1) {
console.error('Raw video streams not available!');
dlFailed = true;
}
} else {
console.warn('Selected stream with %s hardsubs not available', langsData.locale2language(options.hslang).language);
if (hsLangs.length > 0) {
@ -1968,15 +1976,12 @@ export default class Crunchy implements ServiceClass {
astreams = astreams.filter((s) => {
return s.hardsub_lang == '-';
});
if (vstreams.length < 1) {
console.warn('Raw video streams not available!');
if (hsLangs.length > 0) {
console.warn('Try hardsubs stream:', hsLangs.join(', '));
}
dlFailed = true;
}
if (astreams.length < 1) {
console.warn('Raw audio streams not available!');
console.warn('No audio streams found, using video audio streams instead');
astreams = vstreams;
}
if (vstreams.length < 1) {
console.error('Raw video streams not available!');
if (hsLangs.length > 0) {
console.warn('Try hardsubs stream:', hsLangs.join(', '));
}