Skip to content
This repository has been archived by the owner on Feb 23, 2021. It is now read-only.

Commit

Permalink
Fixing issues
Browse files Browse the repository at this point in the history
  • Loading branch information
fgardt committed Feb 5, 2017
1 parent a596c93 commit 43a5e4d
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions lib/basic.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ module.exports = {
} catch (e) {
console.warn("[Catched] " + e);
info = module.exports.info;
throw e;
}
fs.closeSync(file);
return info;
Expand Down Expand Up @@ -227,9 +226,9 @@ module.exports = {
downloading = true;
if (module.exports.debug) console.log("Downloading " + name + " (" + id + ")");
try {
youtubedl.exec(id, ["-x", "--audio-format", "mp3", "--audio-quality", "0", "--embed-thumbnail", "--metadata-from-title", "'%(artist)s - %(title)s'", "-o", "'%(title)s.%(ext)s'"], {cwd: dir}, function(err, output) {
if (err) console.warn("Error [" + name + "]", e);
if (module.exports.debug && !err) console.log("Finished "+ name);
youtubedl.exec("https://www.youtube.com/watch?v=" + id, ["-x", "--audio-format", "mp3", "--audio-quality", "0", "--embed-thumbnail", "--metadata-from-title", "'%(artist)s - %(title)s'", "-o", "'%(title)s.%(ext)s'"], {cwd: dir}, function(e, output) {
if (e) console.warn("Error [" + name + "]", e);
if (module.exports.debug && !e) console.log("Finished "+ name);
module.exports.info.data.download.complete++;
module.exports.info.data.activeDl--;
module.exports.info.playlists[uuid].local[id] = {"id" : id, "name" : name};
Expand Down

0 comments on commit 43a5e4d

Please sign in to comment.