From d4bfcbef47a02a38bf5a6efb19634c5939a2c2ea Mon Sep 17 00:00:00 2001 From: PCoder Date: Tue, 31 Dec 2019 22:55:53 +0530 Subject: [PATCH] Use message as returned by stripe --- utils/stripe_utils.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/utils/stripe_utils.py b/utils/stripe_utils.py index cdb5182b..de16fe4b 100644 --- a/utils/stripe_utils.py +++ b/utils/stripe_utils.py @@ -43,21 +43,21 @@ def handleStripeError(f): # Authentication with Stripe's API failed # (maybe you changed API keys recently) logger.error(str(e)) - response.update({'error': common_message}) + response.update({'error': str(e)}) return response except stripe.error.APIConnectionError as e: logger.error(str(e)) - response.update({'error': common_message}) + response.update({'error': str(e)}) return response except stripe.error.StripeError as e: # maybe send email logger.error(str(e)) - response.update({'error': common_message}) + response.update({'error': str(e)}) return response except Exception as e: # maybe send email logger.error(str(e)) - response.update({'error': common_message}) + response.update({'error': str(e)}) return response return handleProblems