Adyen / adyen-shopware6

Adyen Payment plugin for Shopware 6
MIT License
21 stars 20 forks source link

FrontendProxyController.php - change CartOrderRoute to AbstractCartOrderRoute #492

Open sascha-seyfert opened 2 weeks ago

sascha-seyfert commented 2 weeks ago

Hello dear Adyen team,

There is a bug in the Adyen Shopware 6 plugin.

This error occurs in connection with a third-party plugin.

Name of the third-party plugin: Conversion Checkout for Shopware 6 Store: https://store.shopware.com/en/loyxx57434896565m/conversion-checkout-for-shopware-6.html

Description of the problem / clear instructions for reproduction:

[2024-02-09T08:06:36.056488+00:00] request.CRITICAL: Uncaught PHP Exception TypeError: "Cannot assign LoyxxSW6ConversionCheckout\Core\Checkout\Cart\SalesChannel\CartOrderRoute to property Adyen\Shopware\Storefront\Controller\FrontendProxyController: :$cartOrderRoute of type Shopware\Core\Checkout\Cart\SalesChannel\CartOrderRoute" at FrontendProxyController.php line 71 {"exception":"[object] (TypeError(code: 0): Cannot assign LoyxxSW6ConversionCheckout\Core\Checkout\ \Cart\SalesChannel\CartOrderRoute to property Adyen\Shopware\Storefront\Controller\FrontendProxyController::$cartOrderRoute of type Shopware\Core\Checkout\Cart\SalesChannel\CartOrderRoute at /var/www /clients/client1/web2/web/production/releases/193/vendor/adyen/adyen-shopware6/src/Storefront/Controller/FrontendProxyController.php:71)"} []

PHP class: Adyen\Shopware\Storefront\Controller\FrontendProxyController

Change:

https://github.com/Adyen/adyen-shopware6/blob/a8a59eba9d29b6be1677ba9931dfe66b8e0b2cd8/src/Storefront/Controller/FrontendProxyController.php#L54

RokPopov commented 2 weeks ago

Hi @sascha-seyfert,

Thank you for reporting this issue. I have created an internal ticket for handling this. Once the fix is merged with the develop branch, this issue will automatically be closed.

Kind regards, Rok

MelvinAchterhuis commented 1 week ago

@RokPopov , same goes for PostNL:

Cannot assign PostNL\Shopware6\Controller\StoreApi\ContextSwitchRoute to property Adyen\Shopware\Storefront\Controller\FrontendProxyController::$contextSwitchRoute of type Shopware\Core\System\SalesChannel\SalesChannel\ContextSwitchRoute

See: https://github.com/Adyen/adyen-shopware6/pull/499/files