set debug property on cr/hd

This commit is contained in:
AnimeDL 2023-07-04 22:45:52 -07:00
parent 4c870f0640
commit f6506fefcc
2 changed files with 5 additions and 0 deletions

View file

@ -63,6 +63,8 @@ export default class Crunchy implements ServiceClass {
public async cli() {
console.info(`\n=== Multi Downloader NX ${packageJson.version} ===\n`);
const argv = yargs.appArgv(this.cfg.cli);
if (argv.debug)
this.debug = true;
// load binaries
this.cfg.bin = await yamlCfg.loadBinCfg();

View file

@ -85,6 +85,8 @@ export default class Hidive implements ServiceClass {
public async cli() {
console.info(`\n=== Multi Downloader NX ${packageJson.version} ===\n`);
const argv = yargs.appArgv(this.cfg.cli);
if (argv.debug)
this.debug = true;
//below is for quickly testing API calls
/*const searchItems = await this.reqData('Search', {'Query':''});
@ -698,6 +700,7 @@ export default class Hidive implements ServiceClass {
const getVttContent = await this.req.getData(await this.genSubsUrl('vtt', subsXUrl));
if (getCssContent.ok && getVttContent.ok && getCssContent.res && getVttContent.res) {
//vttConvert(getVttContent.res.body, false, subLang.name, fontSize);
//TODO: look into potentially having an option for native fontSize
const sBody = vtt(undefined, options.fontSize, getVttContent.res.body, getCssContent.res.body, subsMargin, options.fontName);
sxData.title = `${subLang.language} / ${sxData.title}`;
sxData.fonts = fontsData.assFonts(sBody) as Font[];