This commit is contained in:
Izuco 2022-07-04 18:19:26 +02:00
parent 4984a2bfbf
commit b8432270b6
No known key found for this signature in database
GPG key ID: E9CBE9E4EF3A1BFA
3 changed files with 6 additions and 5 deletions

View file

@ -2,7 +2,8 @@ name: Bug
description: File a bug report
assignees:
- izu-co
labels: bug
labels:
- bug
title: "BUG"
body:
- type: markdown

View file

@ -90,7 +90,7 @@ export default class Crunchy implements ServiceClass {
}
else if(argv.new){
await this.refreshToken();
await this.getNewlyAdded();
await this.getNewlyAdded(argv.page);
}
else if(argv.search && argv.search.length > 2){
await this.refreshToken();
@ -651,8 +651,8 @@ export default class Crunchy implements ServiceClass {
}
// calculate pages
const itemPad = parseInt(new URL(newlyAddedResults.__href__, domain.api_beta).searchParams.get('start') as string);
const pageCur = itemPad > 0 ? Math.ceil(itemPad/5) + 1 : 1;
const pageMax = Math.ceil(newlyAddedResults.total/5);
const pageCur = itemPad > 0 ? Math.ceil(itemPad/25) + 1 : 1;
const pageMax = Math.ceil(newlyAddedResults.total/25);
console.log(` [INFO] Total results: ${newlyAddedResults.total} (Page: ${pageCur}/${pageMax})`);
}

View file

@ -24,7 +24,7 @@ type BuildTypes = `${'ubuntu'|'windows'|'macos'|'arm'}64`
async function buildGUI(buildType: BuildTypes) {
execSync(`npx electron-builder build --publish=never ${getCommand(buildType)}`, { stdio: [0,1,2] });
execSync(`7z a -t7z "../${buildsDir}/multi-downloader-nx-${buildType}-gui.7z" ${getOutputFileName(buildType).map(a => `"${a}"`).join(" ")}`,{
execSync(`7z a -t7z "../${buildsDir}/multi-downloader-nx-${buildType}-gui.7z" ${getOutputFileName(buildType).map(a => `"${a}"`).join(' ')}`,{
stdio:[0,1,2],
cwd: path.join('dist')
});