diff --git a/lib/http/client.js b/lib/http/client.js index 9ee25c5e..43973ec3 100644 --- a/lib/http/client.js +++ b/lib/http/client.js @@ -6,7 +6,7 @@ */ 'use strict'; - +const assert = require('assert'); const Network = require('../protocol/network'); const AsyncObject = require('../utils/asyncobject'); const RPCClient = require('./rpcclient'); @@ -493,6 +493,7 @@ HTTPClient.prototype.getWallets = function getWallets() { */ HTTPClient.prototype.createWallet = function createWallet(options) { + assert(options.id, 'Must pass an id parameter') return this._put(`/wallet/${options.id}`, options); };