diff --git a/lib/bcoin/http/rpcclient.js b/lib/bcoin/http/rpcclient.js index d3bc34f7..5f8a2812 100644 --- a/lib/bcoin/http/rpcclient.js +++ b/lib/bcoin/http/rpcclient.js @@ -64,6 +64,9 @@ RPCClient.prototype.call = function call(method, params, callback) { if (!body) return callback(); + if (res.statusCode === 400) + return callback(null, body.result); + if (res.statusCode !== 200) { if (body.error) return callback(new Error(body.error.message));