StripeController: give 404 response to charge notice with no buyer.

This commit is contained in:
Brian Simpson
2013-11-19 10:13:12 -05:00
parent 4fe8c5d427
commit 9eaa928b7f

View File

@@ -820,6 +820,8 @@ class StripeController(GoldPaymentController):
# db replication lag may cause the account lookup to fail
if charge_date < timeago('1 hour'):
raise ValueError('no buyer for charge: %s' % charge.id)
else:
self.abort404()
webhook = Webhook(transaction_id=transaction_id,
subscr_id=customer_id, pennies=pennies,
months=months, goldtype='autorenew',