Skip to content
This repository has been archived by the owner on Dec 3, 2023. It is now read-only.

Commit

Permalink
fix for failed download with no subtitles when requested
Browse files Browse the repository at this point in the history
consistency
  • Loading branch information
przemyslawpluta committed Aug 1, 2014
1 parent 82a48a4 commit 19c13af
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/youtube-dl.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,15 +120,15 @@ function call(video, args1, args2, options, callback) {
if (stderr) {

// Try once to download video if no subtitles available
if (!options.nocc && isNoSubsRegex.test(stderr)) {
if (!options.nosubs && isNoSubsRegex.test(stderr)) {
var cleanupOpt = opt[1].reverse();

subs.map(function map(item) {
var target = reIndexOf(cleanupOpt, item);
if (target > -1) { cleanupOpt.splice(target, 1); }
});

options.nocc = true;
options.nosubs = true;

return call(video, args1, cleanupOpt.reverse(), options, callback);

Expand Down

0 comments on commit 19c13af

Please sign in to comment.