mirror of
https://github.com/donl/plivo-node.git
synced 2026-06-30 06:12:08 -06:00
Update powerpacks.js
This commit is contained in:
parent
e3aa4eb598
commit
6b91a08c36
1 changed files with 12 additions and 4 deletions
|
|
@ -99,8 +99,12 @@ export class Powerpack extends PlivoResource {
|
|||
return super.customexecuteAction(path.toString().trim(), 'POST', params);
|
||||
}
|
||||
remove_number(number, unrent = false) {
|
||||
var params;
|
||||
params['unrent'] = unrent;
|
||||
var params = {};
|
||||
if (typeof unrent === 'boolean') {
|
||||
params['unrent'] = unrent.toString();
|
||||
} else {
|
||||
params['unrent'] = unrent;
|
||||
}
|
||||
let path = 'NumberPool/' + this.number_pool_id + '/Number/' + number + '/';
|
||||
return super.customexecuteAction(path.toString().trim(), 'DELETE', params);
|
||||
}
|
||||
|
|
@ -281,8 +285,12 @@ export class Numbers extends PlivoResource {
|
|||
return super.customexecuteAction(path.toString().trim(), 'POST', params);
|
||||
}
|
||||
remove(number, unrent = false) {
|
||||
var params;
|
||||
params['unrent'] = unrent;
|
||||
var params = {};
|
||||
if (typeof unrent === 'boolean') {
|
||||
params['unrent'] = unrent.toString();
|
||||
} else {
|
||||
params['unrent'] = unrent;
|
||||
}
|
||||
let path = 'NumberPool/' + this.number_pool_id + '/Number/' + number + '/';
|
||||
return super.customexecuteAction(path.toString().trim(), 'DELETE', params);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue