paypro: ripesha refund_to pubkeys.

This commit is contained in:
Christopher Jeffrey 2014-08-01 15:00:38 -07:00 committed by Manuel Araoz
parent c471983a58
commit 3a73f2453c
1 changed files with 2 additions and 0 deletions

View File

@ -978,6 +978,8 @@ Wallet.prototype.sendPaymentTx = function(ntxid, options, cb) {
|| self.publicKeyRing.getPubKeys(0, false, this.getMyCopayerId())[0];
if (options.refund_to) {
// pubkey needs to be ripesha'd
options.refund_to = bitcore.sha256ripe160(options.refund_to);
var total = txp.merchant.pr.pd.outputs.reduce(function(total, _, i) {
return total.add(bignum.fromBuffer(tx.outs[i].v, {
endian: 'little',