woocommerce / woocommerce-gateway-stripe

The official Stripe Payment Gateway for WooCommerce
https://wordpress.org/plugins/woocommerce-gateway-stripe/
234 stars 206 forks source link

PHP Notice when purchasing a subscription with free trial #2663

Open a-danae opened 1 year ago

a-danae commented 1 year ago

Describe the bug The following PHP notice is logged when purchasing a subscription product with free trial.

PHP Notice: Trying to get property 'type' of non-object in /var/www/html/wp-content/plugins/woocommerce-gateway-stripe/includes/abstracts/abstract-wc-stripe-payment-gateway.php on line 1641

To Reproduce Steps to reproduce the behavior:

  1. Install WC Subscriptions
  2. Make sure UPE is disabled
  3. Create a subscription product. Set it to $10 per month, with a 10-day free trial
  4. As a shopper, purchase this subscription
  5. Go to the debug.log file and notice this entry

Expected behavior Purchasing a subscription with a free trial must not generate PHP notices.

Additional context I tried with both EUR and INR as the store currency.

github-actions[bot] commented 1 month ago

Hi, This issue has gone 150 days (5 months) without any activity. This means it is time for a check-in to make sure it is still relevant. If you are still experiencing this issue with the latest version, you can help the project by responding to confirm the problem and by providing any updated reproduction steps. Thanks for helping out.

github-actions[bot] commented 5 days ago

This issue has gone 180 days (6 months) without any activity.