trypost/tests/Unit/Support/Billing
Paulo Castellano 2c1cd4ec61 Ignore never-started subscriptions when detecting a first-time customer
A raw subscriptions()->exists() check treated a leftover incomplete /
incomplete_expired row — which Cashier persists when a first payment
fails or a 3DS challenge is abandoned — as a prior subscription, so a
genuinely new customer retrying after a failed first attempt lost the
$1 coupon and was charged full price. Exclude those never-started
statuses so only a subscription that actually started (active, canceled,
etc.) marks the account as a returning customer.
2026-07-09 16:03:25 -03:00
..
FirstMonthCheckoutDiscountTest.php Ignore never-started subscriptions when detecting a first-time customer 2026-07-09 16:03:25 -03:00