SwedbankPay/swedbank-pay-woocommerce-checkout

Critical error when a product have been deleted

craftycrafter90 opened this issue · 2 comments

If a customer have purchased a product which then have been removed from the shop the order can't be opened properly.
The Swedbank window shows "Critical error message".

If Swedbank is deactivated the order with info and products shows as usual.
error

When trying to open the order in WC, this email is triggered as well.

Ett fel av typen E_ERROR uppstod på rad 271 i följande fil: /wp-content/plugins/swedbank-pay-checkout-new/vendor/swedbank-pay/swedbank-pay-woocommerce-core/src/SwedbankPay/Core/Adapter/WC_Adapter.php. Felorsak: Uncaught Error: Call to a member function get_image_id() on bool in /wp-content/plugins/swedbank-pay-checkout-new/vendor/swedbank-pay/swedbank-pay-woocommerce-core/src/SwedbankPay/Core/Adapter/WC_Adapter.php:271
Stack trace:
#0 /wp-content/plugins/swedbank-pay-checkout-new/vendor/swedbank-pay/swedbank-pay-woocommerce-core/src/SwedbankPay/Core/Core.php(146): SwedbankPay\Core\Adapter\WC_Adapter->getOrderData(185315)
#1 /wp-content/plugins/swedbank-pay-checkout-new/vendor/swedbank-pay/swedbank-pay-woocommerce-core/src/SwedbankPay/Core/Library/OrderAction.php(39): SwedbankPay\Core\Core->getOrder(185315)
#2 /wp-content/plugins/swedbank-pay-checkout-new/templates/admin/payment-actions.php(36): SwedbankPay\Core\Core->canCapture(185315)
#3 /wp-content/plugins/woocommerce/includes/wc-core-functions.php(345): include('/home/folder/...')
#4 /wp-content/plugins/swed