mirror of
https://github.com/anidl/multi-downloader-nx.git
synced 2026-03-11 17:45:30 +00:00
revert hidive fallback logic.
Again a core change to how all other services work just for hidive doesn't seem like the right course of action.
This commit is contained in:
parent
2b30c8e458
commit
03ab5007d6
1 changed files with 2 additions and 13 deletions
15
hidive.ts
15
hidive.ts
|
|
@ -760,19 +760,8 @@ export default class Hidive implements ServiceClass {
|
|||
}
|
||||
}
|
||||
if (chosenAudios.length == 0) {
|
||||
console.warn(`Chosen audio language(s) does not exist for episode ${selectedEpisode.episodeInformation.episodeNumber}, falling back to first available audio`);
|
||||
if (audios.length > 0) {
|
||||
let chosenAudioQuality = options.q === 0 ? audios.length : options.q;
|
||||
if(chosenAudioQuality > audios.length) {
|
||||
chosenAudioQuality = audios.length;
|
||||
}
|
||||
chosenAudioQuality--;
|
||||
chosenAudios.push(audios[chosenAudioQuality]);
|
||||
console.info(`Using audio track: ${audios[chosenAudioQuality].language.code || 'unknown'}`);
|
||||
} else {
|
||||
console.error(`No audio tracks available for episode ${selectedEpisode.episodeInformation.episodeNumber}`);
|
||||
return undefined;
|
||||
}
|
||||
console.error(`Chosen audio language(s) does not exist for episode ${selectedEpisode.episodeInformation.episodeNumber}`);
|
||||
return undefined;
|
||||
}
|
||||
|
||||
const fileName = parseFileName(options.fileName, variables, options.numbers, options.override).join(path.sep);
|
||||
|
|
|
|||
Loading…
Reference in a new issue