Skip to content

Commit

Permalink
fix(wallet): handle signPsbtRequest with Bluebird
Browse files Browse the repository at this point in the history
Fixes the `callback is not a function` error

Ticket: BTC-1351

TICKET: BTC-1351
  • Loading branch information
lcovar committed Nov 27, 2024
1 parent 575a6b7 commit 1798b4b
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions modules/sdk-api/src/v1/wallet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -899,11 +899,7 @@ Wallet.prototype.signTransaction = function (params, callback) {
params = _.extend({}, params);

if (params.psbt) {
try {
return callback(null, signPsbtRequest(params));
} catch (e) {
return callback(e);
}
return Bluebird.try(() => signPsbtRequest(params)).nodeify(callback);
}

common.validateParams(params, ['transactionHex'], [], callback);
Expand Down

0 comments on commit 1798b4b

Please sign in to comment.