Hydra
Bug library · coupon · math

Fixed-amount coupon broken

Fixed-amount coupons are divided by 100 a second time, so HOLIDAY5 takes off 5 cents.

Breaks: holdout · expected from Kane: missed · Only the hidden holdout uses a fixed-amount coupon; the main spec cannot see it.

The diff

lib/coupons.ts
- : coupon.amountCents;
+ : Math.round(coupon.amountCents / 100);

Matches

No recorded match has planted this bug yet.