adyen-magento2 icon indicating copy to clipboard operation
adyen-magento2 copied to clipboard

Mutation adyenPaymentDetails - Support exception message

Open dimitriBouteille opened this issue 1 year ago • 1 comments

Hi, It is possible to integrate this feature in version 9.0.0 ?

In the future, use the message and the code passed by the exception. Since currently the message and code are not being passed, use this generic message.

try {
            return $this->getAdyenPaymentStatusDataProvider->getGetAdyenPaymentDetails($this->jsonSerializer->serialize($payload));
        } catch (Exception $exception) {
            $this->adyenLogger->error(sprintf(
                'GraphQl payment details call failed with error message: %s',
                $exception->getMessage()
            ));
            // In the future, use the message and the code passed by the exception. Since currently the message and code are not
            // being passed, use this generic message.
            throw new GraphQlAdyenException(__('An unknown error has occurred'), null, 000);
        }

https://github.com/Adyen/adyen-magento2/blob/8ee726d9826398d83aaf97c340f0244168801e21/Model/Resolver/GetAdyenPaymentDetails.php#L126

dimitriBouteille avatar May 16 '23 10:05 dimitriBouteille