diff --git a/bin/cli b/bin/cli index d7c9b2ee..25b930fd 100755 --- a/bin/cli +++ b/bin/cli @@ -262,7 +262,7 @@ CLI.prototype.signTX = co(function* signTX() { this.log(tx); }); -CLI.prototype.zap = co(function* zap() { +CLI.prototype.zapWallet = co(function* zapWallet() { var age = (this.config.age >>> 0) || 72 * 60 * 60; yield this.wallet.zap(this.config.account, age); this.log('Zapped!'); @@ -303,9 +303,9 @@ CLI.prototype.rescan = co(function* rescan() { this.log('Rescanning...'); }); -CLI.prototype.zapAll = co(function* zapAll() { +CLI.prototype.zap = co(function* zap() { var age = +this.argv[0] || 72 * 3600; - yield this.client.zapAll(age); + yield this.client.zap(age); this.log('Zapped.'); }); @@ -428,7 +428,7 @@ CLI.prototype.handleWallet = co(function* handleWallet() { case 'send': return yield this.sendTX(); case 'zap': - return yield this.zap(); + return yield this.zapWallet(); case 'tx': return yield this.getDetails(); case 'view': @@ -500,7 +500,7 @@ CLI.prototype.handleNode = co(function* handleNode() { case 'rescan': return yield this.rescan(); case 'zap': - return yield this.zapAll(); + return yield this.zap(); case 'backup': return yield this.backup(); case 'rpc': diff --git a/lib/http/client.js b/lib/http/client.js index bc28102b..c8527a66 100644 --- a/lib/http/client.js +++ b/lib/http/client.js @@ -364,7 +364,7 @@ HTTPClient.prototype.rescan = function rescan(hash) { * @returns {Promise} */ -HTTPClient.prototype.zapAll = function zapAll(age) { +HTTPClient.prototype.zap = function zap(age) { var options = { age: age }; return this._post('/zap', options); }; @@ -677,7 +677,7 @@ HTTPClient.prototype.fillCoins = function fillCoins(id, tx) { * @returns {Promise} */ -HTTPClient.prototype.zap = function zap(id, account, age) { +HTTPClient.prototype.zapWallet = function zapWallet(id, account, age) { var body = { account: account, age: age diff --git a/lib/http/wallet.js b/lib/http/wallet.js index bd754409..6355f5e1 100644 --- a/lib/http/wallet.js +++ b/lib/http/wallet.js @@ -205,7 +205,7 @@ HTTPWallet.prototype.getCoin = function getCoin(account, hash, index) { */ HTTPWallet.prototype.zap = function zap(account, age) { - return this.client.zap(this.id, account, age); + return this.client.zapWallet(this.id, account, age); }; /**