MultiSafepay / Magento2Msp

MultiSafepay plugin for Magento 2 (Deprecated) see: https://github.com/MultiSafepay/magento2
Open Software License 3.0
29 stars 25 forks source link

Payment link is not output because a wrong data type #132

Closed skynixukraine closed 4 years ago

skynixukraine commented 4 years ago

To Reproduce request a payment link GET /rest/V1/multisafepay/mine/payment-url/

Here https://github.com/MultiSafepay/Magento2Msp/blob/master/Model/PaymentUrl.php on line 73 it will always fail on validation. Because $customerId is INTEGER and $order->getCustomerId() is STRING A quick turnaround would be to do the following:

if ($customerId && $customerId !== (int)$order->getCustomerId()) { return ''; }

Jasper-MultiSafepay commented 4 years ago

@skynixukraine I have a look at it in the current sprint. For now you use the quick workaround, I will keep you updated on the progress

Jasper-MultiSafepay commented 4 years ago

@skynixukraine Confirmed, we will apply the same fix in the upcoming version