tolerate zero-value payments
This commit is contained in:
parent
2667d741e9
commit
1c0cce3f58
@ -145,7 +145,8 @@ export async function getTotalPaymentCost(
|
|||||||
costs.push(pcs.coinContributions[i]);
|
costs.push(pcs.coinContributions[i]);
|
||||||
costs.push(refreshCost);
|
costs.push(refreshCost);
|
||||||
}
|
}
|
||||||
return Amounts.sum(costs).amount;
|
const zero = Amounts.getZero(pcs.paymentAmount.currency);
|
||||||
|
return Amounts.sum([zero, ...costs]).amount;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user