Skip to content
Snippets Groups Projects
Commit 6eb4178a authored by Kurund Jalmi's avatar Kurund Jalmi
Browse files

return correct error code for invalid request exception

parent aaca1d47
No related branches found
No related tags found
1 merge request!207return correct error code for invalid request exception
...@@ -287,6 +287,7 @@ class CRM_Core_Payment_Stripe extends CRM_Core_Payment { ...@@ -287,6 +287,7 @@ class CRM_Core_Payment_Stripe extends CRM_Core_Payment {
// Too many requests made to the API too quickly // Too many requests made to the API too quickly
case 'Stripe\Exception\InvalidRequestException': case 'Stripe\Exception\InvalidRequestException':
// Invalid parameters were supplied to Stripe's API // Invalid parameters were supplied to Stripe's API
$genericError['code'] = $e->getError()->code;
case 'Stripe\Exception\AuthenticationException': case 'Stripe\Exception\AuthenticationException':
// Authentication with Stripe's API failed // Authentication with Stripe's API failed
// (maybe you changed API keys recently) // (maybe you changed API keys recently)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment