While testing a payment that requires 3D auth, I've noticed that the hasIncompletePayment() method always returns false when used as $user->hasIncompletePayment(), even tough there's a subscription stripe_status with the value of incomplete.
If I'm calling the hasIncompletePayment() method on a subscription instance, such as $user->subscription('Name')->hasIncompletePayment(), then it returns true.
Shouldn't both return true? There's only 1 subscription in the subscriptions table, and it has the incomplete state as previously mentioned.
Have you set up webhooks properly?
Yes, webhooks are properly setup, if I complete the payment (trough the confirmation checkout), the subscription gets updated as it should. Also if I go under Stripe's Dashboard > Developers > Webhooks > Webhooks attempts, all of the Webhooks have the status "Succeeded".
Is there anything else I could verify?
I think I know what's wrong. In beta.2 there's no parameter to pass the name of the subscription along. This was added later in https://github.com/laravel/cashier/pull/733 but not yet released. Can you try to pull in dev-master and pass in the name of your subscription?
Indeed that was it. After moving to dev-master branch it started to work. The docs example does not indicate that this method requires a parameter to work, and upon inspecting the method myself, the method was not accepting any parameters, which added to the confusion.
Thank you for your titanic work.
Hey @codefir, glad you got it working.
The docs example does not indicate that this method requires a parameter to work
I've updated this so it's clear that a subscription name can be passed.
Most helpful comment
Hey @codefir, glad you got it working.
I've updated this so it's clear that a subscription name can be passed.