Browse Source

Merge pull request #399 from isocolsky/fix/derivation-strategy

restore derivation strategy on txps
activeAddress
Matias Alejo Garcia 9 years ago
parent
commit
28c06e09bc
  1. 2
      lib/model/txproposal.js
  2. 1
      lib/server.js

2
lib/model/txproposal.js

@ -79,6 +79,7 @@ TxProposal.create = function(opts) {
x.proposalSignaturePubKey = opts.proposalSignaturePubKey;
x.proposalSignaturePubKeySig = opts.proposalSignaturePubKeySig;
x.addressType = opts.addressType || Constants.SCRIPT_TYPES.P2SH;
x.derivationStrategy = opts.derivationStrategy || Constants.DERIVATION_STRATEGIES.BIP45;
x.customData = opts.customData;
if (_.isFunction(TxProposal._create[x.type])) {
@ -127,6 +128,7 @@ TxProposal.fromObj = function(obj) {
x.proposalSignaturePubKey = obj.proposalSignaturePubKey;
x.proposalSignaturePubKeySig = obj.proposalSignaturePubKeySig;
x.addressType = obj.addressType || Constants.SCRIPT_TYPES.P2SH;
x.derivationStrategy = obj.derivationStrategy || Constants.DERIVATION_STRATEGIES.BIP45;
x.customData = obj.customData;
return x;

1
lib/server.js

@ -1286,6 +1286,7 @@ WalletService.prototype.createTx = function(opts, cb) {
walletN: wallet.n,
excludeUnconfirmedUtxos: !!opts.excludeUnconfirmedUtxos,
addressType: wallet.addressType,
derivationStrategy: wallet.derivationStrategy,
customData: opts.customData,
};

Loading…
Cancel
Save