Closed allamgr closed 7 years ago
Hi, @allamgr, unfortunately, we don't provide investigation for 3d party extensions.
I've tested Magento Express Checkout on 2.1.3 version and all works fine. Please, try to reproduce your issue with Express Checkout from Magento and update this issue.
We are closing this issue because it hasn’t been updated in more than two weeks.
If you still can reproduce the issue, please, be free to reopen it.
I get a similar issue without the hack on 2.1.9.
The problem is a warning, but we develop with these turned on. On attempting to place the order, returning from PayPa successfully:
[2017-10-04 11:33:56] main.CRITICAL: Exception message: Warning: array_key_exists(): The first argument should be either a string or an integer in .../web-root/vendor/magento/module-sales/Model/Order/Payment.php on line 359 Trace: #0 [internal function]: Magento\Framework\App\ErrorHandler->handler(2, 'array_key_exist...', '...', 359, Array)
...
I've tracked down the issue to magento/module-paypal/Model/Express.php line 389:
$status = true;
This then gets set on the order model on line 431.
When we get to magento/module-sales/Model/Order/Payment.php it gets the status from the order as TRUE, so at line 359 of that file it throws a PHP error because a boolean is not a valid input to the array_key_exists function.
As a workaround I've created a plugin for Paypal\Model\Express which sets order status to null if it's set to true. This is finally allowing orders to go through in Order mode.
The issue is reproducible in Magento v.2.2.3 (PHP warnings on).
The issue is marked closed, but per the above it seems to be reproducible on the late Magento releases. Could you please reopen?
Preconditions
Merchant Country: Dominican Republic
Paypal Express Checkout Sandbox Mode: Yes API Uses Proxy: No Enable this solution: Yes Enable In-Context Checkout Experience: Yes --Advance Config --Payment Applicable From: All Allowed Contries --Debug Mode: Yes --Enable SSL verification: Yes --Transfer Cart Line Items: Yes --Transfer Shipping Options: No --Require Customer's Billing Address: No --Billing Agreement Signup: Never --Skip Order Review Step: Yes
Steps to reproduce
Expected result
Actual result