You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Adyen\HttpClient\CurlClient there are 2 private methods:
handleCurlError
handleResultError
They both returns the same exception: \Adyen\AdyenException
So there's no way to distinguish connection errors and "api result" errors (i.e that would allow to decide to retry payment or not.)
My proposal is to return two different exceptions:
\Adyen\ConnectionExceptionin handleCurlError
\Adyen\AdyenException in handleResultError
The text was updated successfully, but these errors were encountered:
I understand your issue. There is a way to distinguish the error based on the message of the exception but would be indeed better to use different exception classes so you can create your own catches. I will make a change in the code to make this possible.
In
Adyen\HttpClient\CurlClient
there are 2 private methods:They both returns the same exception:
\Adyen\AdyenException
So there's no way to distinguish connection errors and "api result" errors (i.e that would allow to decide to retry payment or not.)
My proposal is to return two different exceptions:
\Adyen\ConnectionException
in handleCurlError\Adyen\AdyenException
in handleResultErrorThe text was updated successfully, but these errors were encountered: