# Klarna Fehler /checkout/cart fatal error

**URL:** <https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759>\
**Category:** Shopware 5\
**Created:** [1. April 2022 um 06:59 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759 "2022-04-01T06:59:38Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![quebag](https://avatars.discourse-cdn.com/v4/letter/q/c67d28/32.png) [@quebag](https://forum.shopware.com/u/quebag)\
**Post date:** [1. April 2022 um 06:59 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/1 "2022-04-01T06:59:38Z")

</div>

Kunden haben uns darauf hingewiesen.

Ware im Warenkorb.  
Fehler kommt dann bei „Warenkorb anzeigen“ und auch bei „zur Kasse“.

on site messaging deaktiviert  
php Version 8.0  
Shopware 5.7.7

```auto
Fatal error: Uncaught TypeError: str_replace(): Argument #3 ($subject) must be of type array|string, float given in /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/vendor/k10r/klarna-ordermanagement/src/Components/Transformer/LineItemTransformer.php:298 Stack trace: #0 /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/vendor/k10r/klarna-ordermanagement/src/Components/Transformer/LineItemTransformer.php(298): str_replace() #1 /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/vendor/k10r/klarna-ordermanagement/src/Components/Transformer/LineItemTransformer.php(163): BestitKlarnaOrderManagement\Components\Transformer\LineItemTransformer->getUnitPriceWithTax() #2 /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/vendor/k10r/klarna-ordermanagement/src/Components/Transformer/LineItemTransformer.php(105): BestitKlarnaOrderManagement\Components\Transformer\LineItemTransformer->toKlarnaModel() #3 /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/Components/Transformer/BasketTransformer.php(127): BestitKlarnaOrderManagement\Components\Transformer\LineItemTransformer->toKlarnaModelList() #4 /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/Components/Facade/Session.php(69): BestitKlarnaPayments\Components\Transformer\BasketTransformer->toKlarnaOrder() #5 /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/Components/SessionHandler.php(48): BestitKlarnaPayments\Components\Facade\Session->createKlarnaSession() #6 /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/Subscriber/Frontend/Checkout.php(130): BestitKlarnaPayments\Components\SessionHandler->createKlarnaSessionAndUpdateSwSession() #7 /var/www/clients/client1/web6/web/engine/Library/Enlight/Event/Handler/Default.php(90): BestitKlarnaPayments\Subscriber\Frontend\Checkout->createOrUpdateKlarnaSession() #8 /var/www/clients/client1/web6/web/engine/Library/Enlight/Event/EventManager.php(208): Enlight_Event_Handler_Default->execute() #9 /var/www/clients/client1/web6/web/engine/Library/Enlight/Controller/Action.php(197): Enlight_Event_EventManager->notify() #10 /var/www/clients/client1/web6/web/engine/Library/Enlight/Controller/Dispatcher/Default.php(461): Enlight_Controller_Action->dispatch() #11 /var/www/clients/client1/web6/web/engine/Library/Enlight/Controller/Front.php(225): Enlight_Controller_Dispatcher_Default->dispatch() #12 /var/www/clients/client1/web6/web/engine/Shopware/Kernel.php(197): Enlight_Controller_Front->dispatch() #13 /var/www/clients/client1/web6/web/vendor/symfony/http-kernel/HttpCache/SubRequestHandler.php(85): Shopware\Kernel->handle() #14 /var/www/clients/client1/web6/web/vendor/symfony/http-kernel/HttpCache/HttpCache.php(479): Symfony\Component\HttpKernel\HttpCache\SubRequestHandler::handle() #15 /var/www/clients/client1/web6/web/engine/Shopware/Components/HttpCache/AppCache.php(266): Symfony\Component\HttpKernel\HttpCache\HttpCache->forward() #16 /var/www/clients/client1/web6/web/vendor/symfony/http-kernel/HttpCache/HttpCache.php(452): Shopware\Components\HttpCache\AppCache->forward() #17 /var/www/clients/client1/web6/web/vendor/symfony/http-kernel/HttpCache/HttpCache.php(346): Symfony\Component\HttpKernel\HttpCache\HttpCache->fetch() #18 /var/www/clients/client1/web6/web/engine/Shopware/Components/HttpCache/AppCache.php(192): Symfony\Component\HttpKernel\HttpCache\HttpCache->lookup() #19 /var/www/clients/client1/web6/web/vendor/symfony/http-kernel/HttpCache/HttpCache.php(224): Shopware\Components\HttpCache\AppCache->lookup() #20 /var/www/clients/client1/web6/web/engine/Shopware/Components/HttpCache/AppCache.php(117): Symfony\Component\HttpKernel\HttpCache\HttpCache->handle() #21 /var/www/clients/client1/web6/web/shopware.php(122): Shopware\Components\HttpCache\AppCache->handle() #22 {main} thrown in /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/vendor/k10r/klarna-ordermanagement/src/Components/Transformer/LineItemTransformer.php on line 298

```

---

<div class="post-metadata">

**Author:** ![quebag](https://avatars.discourse-cdn.com/v4/letter/q/c67d28/32.png) [@quebag](https://forum.shopware.com/u/quebag)\
**Post date:** [1. April 2022 um 07:14 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/2 "2022-04-01T07:14:38Z")

</div>

soeben auf PHP 7.4 gewechselt zum Test.

Jetzt klappt es wieder.  
Aber Klarna ist doch bereits für php 8 freigegeben.

---

<div class="post-metadata">

**Author:** ![SCOOPEX](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/scoopex/32/18328_2.png) [@SCOOPEX](https://forum.shopware.com/u/SCOOPEX)\
**Post date:** [1. April 2022 um 08:33 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/3 "2022-04-01T08:33:23Z")

</div>

Hallo,

Du hast da wohl noch das alte Klarna Plugin von BestIT aktiv.

Aktuell ist dieses hier:

> **[Klarna Payments für Shopware 5](https://store.shopware.com/besti13231874259f/klarna-payments-fuer-shopware-5.html)**
>
> Klarna Payments Die einfachen und sicheren Zahlungsarten der Klarna Group ermöglichen 60 Millionen Endkunden grenzüberschreitend bei über 89.000…

Viele Grüße

---

<div class="post-metadata">

**Author:** ![quebag](https://avatars.discourse-cdn.com/v4/letter/q/c67d28/32.png) [@quebag](https://forum.shopware.com/u/quebag)\
**Post date:** [1. April 2022 um 08:34 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/4 "2022-04-01T08:34:57Z")

</div>

Nein. Die Version 2.1.0 von Klarna selbst.

---

<div class="post-metadata">

**Author:** ![SCOOPEX](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/scoopex/32/18328_2.png) [@SCOOPEX](https://forum.shopware.com/u/SCOOPEX)\
**Post date:** [1. April 2022 um 08:35 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/5 "2022-04-01T08:35:55Z")

</div>

Sicher ?

Der Pfad /var/www/clients/client1/web6/web/custom/plugins/BestitKlarnaPayments/Components/Facade/Session.php deutet auf das alte hin.

Viele Grüße

---

<div class="post-metadata">

**Author:** ![quebag](https://avatars.discourse-cdn.com/v4/letter/q/c67d28/32.png) [@quebag](https://forum.shopware.com/u/quebag)\
**Post date:** [1. April 2022 um 08:36 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/6 "2022-04-01T08:36:45Z")

</div>

Das komische an der Sache ist.  
Wir haben trotzdem Bestellungen über Klarna erhalten.

---

<div class="post-metadata">

**Author:** ![quebag](https://avatars.discourse-cdn.com/v4/letter/q/c67d28/32.png) [@quebag](https://forum.shopware.com/u/quebag)\
**Post date:** [1. April 2022 um 08:38 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/7 "2022-04-01T08:38:34Z")

</div>

Ich kann nur sagen was der Plugin-Manager listet. siehe Screenshot

 ![klarna](https://europe1.discourse-cdn.com/flex013/uploads/shopware/original/3X/a/7/a771d4c595981bbe86ab341236bb5c76b0bac8d2.png)

---

<div class="post-metadata">

**Author:** ![quebag](https://avatars.discourse-cdn.com/v4/letter/q/c67d28/32.png) [@quebag](https://forum.shopware.com/u/quebag)\
**Post date:** [1. April 2022 um 08:41 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/8 "2022-04-01T08:41:38Z")

</div>

Aber im FTP ist der Ordnername tatsächlich. „BestitKlarnaPayments“

---

<div class="post-metadata">

**Author:** ![motoroelcom](https://avatars.discourse-cdn.com/v4/letter/m/f9ae1b/32.png) [@motoroelcom](https://forum.shopware.com/u/motoroelcom)\
**Post date:** [26. März 2023 um 15:15 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/9 "2023-03-26T15:15:53Z")

</div>

Hallo @quebag ,

haben Sie hierzu eine Lösung gefunden gehabt? Außer auf PHP7.4 zu bleiben?

Wir haben das gleiche Problem und PHP 7.4 ist mittlerweile veraltet.  
Klarna Plugin 2.3.0 ist im Einsatz und der Unterordner auf dem Server ist auch „BestitKlarnaPayments“

Im voraus vielen Dank!

---

<div class="post-metadata">

**Author:** ![SCOOPEX](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/scoopex/32/18328_2.png) [@SCOOPEX](https://forum.shopware.com/u/SCOOPEX)\
**Post date:** [26. März 2023 um 20:01 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/10 "2023-03-26T20:01:13Z")

</div>

Hallo,

BestitKlarnaPayments ist veraltet und wird soweit mir bekannt, nicht mehr weiterentwickelt. Das muss im /custom Verzeichnis gelöscht werden. Evtl. hast Du da einen Mix aus dem alten und neuen Plugin, welches im Store zur Verfügung steht.

---

<div class="post-metadata">

**Author:** ![motoroelcom](https://avatars.discourse-cdn.com/v4/letter/m/f9ae1b/32.png) [@motoroelcom](https://forum.shopware.com/u/motoroelcom)\
**Post date:** [27. März 2023 um 18:48 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/11 "2023-03-27T18:48:57Z")

</div>

Danke für den Tipp. Das ist echt interessant, da das Plugin erst vor kurzem in betrieb genommen wurde und eine Vermischung eigentlich nicht sein durfte. Ich werde mal probieren das Plugin neu aufzusetzen.

---

<div class="post-metadata">

**Author:** ![PCG](https://avatars.discourse-cdn.com/v4/letter/p/c4cdca/32.png) [@PCG](https://forum.shopware.com/u/PCG)\
**Post date:** [17. Mai 2024 um 06:27 UTC](https://forum.shopware.com/t/klarna-fehler-checkout-cart-fatal-error/93759/12 "2024-05-17T06:27:07Z")

</div>

Gab es hier eine Lösung?

auch die aktuellen Plugins haben eine BestIt Struktur, daran kann es dann nicht liegen?  
BestitKlarnaPayments-2.3.0  
BestitKlarnaPayments-2.4.0

Bei uns läuft die Version 2.3.0 auf PHP 8.0 8.1 & 8.2 wenn ich auch die 2.4.0 gehe, führt der Klick im Checkout mit Zahlungsart Banküberweisung o.ä. auf Kaufen zu einer Fehlermeldung
