listen to address param
This commit is contained in:
parent
fca67fba8a
commit
3f0cfbc7c1
|
@ -277,8 +277,11 @@ ExpressApp.prototype.start = function(opts, cb) {
|
||||||
});
|
});
|
||||||
|
|
||||||
router.get('/v1/utxos/', function(req, res) {
|
router.get('/v1/utxos/', function(req, res) {
|
||||||
|
var opts = {};
|
||||||
|
var addresses = req.query.addresses;
|
||||||
|
if (addresses && _.isString(addresses)) opts.addresses = req.query.addresses.split(',');
|
||||||
getServerWithAuth(req, res, function(server) {
|
getServerWithAuth(req, res, function(server) {
|
||||||
server.getUtxos({}, function(err, utxos) {
|
server.getUtxos(opts, function(err, utxos) {
|
||||||
if (err) return returnError(err, res, req);
|
if (err) return returnError(err, res, req);
|
||||||
res.json(utxos);
|
res.json(utxos);
|
||||||
});
|
});
|
||||||
|
|
|
@ -154,7 +154,6 @@ WalletService.getInstance = function(opts) {
|
||||||
* @param {string} opts.clientVersion - A string that identifies the client issuing the request
|
* @param {string} opts.clientVersion - A string that identifies the client issuing the request
|
||||||
*/
|
*/
|
||||||
WalletService.getInstanceWithAuth = function(opts, cb) {
|
WalletService.getInstanceWithAuth = function(opts, cb) {
|
||||||
|
|
||||||
if (!Utils.checkRequired(opts, ['copayerId', 'message', 'signature']))
|
if (!Utils.checkRequired(opts, ['copayerId', 'message', 'signature']))
|
||||||
return cb(new ClientError('Required argument missing'));
|
return cb(new ClientError('Required argument missing'));
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue