0

When upgrading from 2.1 to 2.3.5, I am now getting the following error when I try to create a new cart rule:

[2020-09-19 15:53:49] main.CRITICAL: Notice: Undefined index: rule_id in /var/www/html/magento2/vendor/stripe/module-payments/Observer/CouponEditObserver.php on line 29 {"exception":"[object] (Exception(code: 0): Notice: Undefined index: rule_id in /var/www/html/magento2/vendor/stripe/module-payments/Observer/CouponEditObserver.php on line 29 at /var/www/html/magento2/vendor/magento/framework/App/ErrorHandler.php:61)"} []

I emailed stripe support and they've told me it's not them. Any help would be appreciated. Thank you.

deicul
  • 1
  • 1

1 Answers1

2

This error related to Stripe Payment extension, when you upgrade Magento from 2.1 to 2.3.5, you have to change PHP version to 7.2 or 7.3 then the error will be happened. The easy way is change the code around line 29 in vendor/stripe/module-payments/Observer/CouponEditObserver.php

if (!isset($data['rule_id']) || !is_numeric($data['rule_id']))
        return;

instead of

if (!is_numeric($data['rule_id']))
        return;
Hieu
  • 21
  • 3
  • Apologies for the late reply. Only just got around to this. Thank you so much! This fixed the issue for me. – deicul Dec 09 '20 at 04:56