Skip to content

Commit

Permalink
Merge pull request #2 from xpiREC/patch-1
Browse files Browse the repository at this point in the history
fix readTaskStatus bad param
  • Loading branch information
franklupo authored Jun 7, 2022
2 parents 6122d34 + 801286d commit 5e43021
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ class PveClientBase {
* @param {string} task Task identifier
* @returns {Promise<bool>}
*/
async taskIsRunning(task) { return await this.readTaskStatus(task).Response.data.status == "running"; }
async taskIsRunning(task) { return await this.readTaskStatus(task).response.data.status == "running"; }

/**
* Get exists status task.
Expand All @@ -410,7 +410,7 @@ class PveClientBase {
* @param {string} task
* @returns {Promise<Result>}
*/
async readTaskStatus(task) { return this.get('/nodes/' + this.#getNodeFromTask(node) + '/tasks/' + task + '/status'); }
async readTaskStatus(task) { return this.get('/nodes/' + this.#getNodeFromTask(task) + '/tasks/' + task + '/status'); }
}

//////////////////////////////////////
Expand Down Expand Up @@ -16655,4 +16655,4 @@ class PVEVersion {



module.exports = { PveClient, PveClientBase, Result, ResponseType }
module.exports = { PveClient, PveClientBase, Result, ResponseType }

0 comments on commit 5e43021

Please sign in to comment.