Fixed issue where videos would be downloaded in the collectInfo stage (#774)

pull/873/head
Tzahi12345 2 years ago
parent 1edcfca6c3
commit 24cabc1f02

@ -245,7 +245,6 @@ async function collectInfo(download_uid) {
options.customOutput = category['custom_output'];
options.noRelativePath = true;
args = await exports.generateArgs(url, type, options, download['user_uid']);
args = utils.filterArgs(args, ['--no-simulate']);
info = await exports.getVideoInfoByURL(url, args, download_uid);
}
@ -552,7 +551,8 @@ exports.generateArgs = async (url, type, options, user_uid = null, simulated = f
exports.getVideoInfoByURL = async (url, args = [], download_uid = null) => {
return new Promise(resolve => {
// remove bad args
const new_args = [...args];
let new_args = [...args];
new_args = utils.filterArgs(new_args, ['--no-simulate']);
const archiveArgIndex = new_args.indexOf('--download-archive');
if (archiveArgIndex !== -1) {

Loading…
Cancel
Save