🐛 Fix the 0-amount bug

When shipping is disabled, the shippingFee is `undefined` which also resulted in the amount to become `NaN`
This commit is contained in:
Philipp Stracker 2024-09-18 17:34:20 +02:00
parent 368ad49d16
commit 643a23c6e0
No known key found for this signature in database

View file

@ -8,6 +8,8 @@ export default class TransactionInfo {
this.#country = country;
this.#currency = currency;
shippingFee = this.toAmount( shippingFee );
total = this.toAmount( total );
this.shippingFee = shippingFee;
this.amount = total - shippingFee;
}