Closed CedNet closed 6 years ago
you mean : https://github.com/MyOnlineStore/omnipay-klarna-checkout/blob/master/src/Message/AbstractRequest.php#L211 (you can also link to lines in github :) )
I guess your are right, we can catch the \TypeError
in the method and return an empty array.
For future reference : https://developers.klarna.com/api/#order-management-api-create-capture
Hi! In Klarnas API the capture request has an empty response body.
In the file https://github.com/MyOnlineStore/omnipay-klarna-checkout/blob/master/src/Message/AbstractRequest.php
On line 211 you are forcing a returntype of array.
The only way around handling this is catching a TypeError exception.
Maybe you should allow the API to handle a null response?