diff --git a/classes/API.js b/classes/API.js index 4fa7e13..821aa42 100644 --- a/classes/API.js +++ b/classes/API.js @@ -91,7 +91,7 @@ export function numsToSizes(...nums) { const ranges = nums.map(findRangeIndex); if (ranges.includes(-1)) throw `${nums} CONTAINS AN INVALID RANGE!`; - return `[${ranges.join(",")}]`; + return `${ranges.join(",")}`; } diff --git a/classes/misc.js b/classes/misc.js index 931701f..7f32476 100644 --- a/classes/misc.js +++ b/classes/misc.js @@ -38,8 +38,9 @@ export class LoadingBar { this.size = size; this.cursor = 0; this.timer = null; + this.y = process.stdout.rows; - cursorTo(process.stdout, this.cursor); + cursorTo(process.stdout, this.cursor, this.y); // draw the initial outline process.stdout.write("\x1B[?25l"); @@ -49,7 +50,7 @@ export class LoadingBar { } increment(amt = 1) { - cursorTo(process.stdout, this.cursor); + cursorTo(process.stdout, this.cursor, this.y); for (let i = 0; i < amt; i++) process.stdout.write("\u2588"); this.cursor += amt; } diff --git a/package.json b/package.json index 49c140e..d3e6a35 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ }, "type": "module", "name": "linkedin-api-js", - "version": "1.0.0-17", + "version": "1.0.0-18", "main": "index.js", "scripts": { "test": "echo \"Error: no test specified\" && exit 1"