Skip to content

Commit

Permalink
Correct typo
Browse files Browse the repository at this point in the history
  • Loading branch information
poxip committed Sep 1, 2017
1 parent 55d0fbf commit 8e55884
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions aa_stripe/models.py
Expand Up @@ -153,7 +153,7 @@ def update_from_stripe_data(self, stripe_coupon, exclude_fields=None, commit=Tru
"""
Update StripeCoupon object with data from stripe.Coupon without calling stripe.Coupon.retrieve.
To only update the object, set the commit param to False.
Returns the number of rows altered, or None if commit is False.
Returns the number of rows altered or None if commit is False.
"""
fields_to_update = self.STRIPE_FIELDS - set(exclude_fields or [])
update_data = {key: stripe_coupon[key] for key in fields_to_update}
Expand Down Expand Up @@ -445,7 +445,7 @@ def _parse_coupon_notification(self, action):
try:
StripeCoupon(coupon_id=coupon_id).save(force_retrieve=True)
except stripe.error.InvalidRequestError:
# do not fail in case the coupon has already been removed from Stripe, before we received the webhook
# do not fail in case the coupon has already been removed from Stripe before we received the webhook
pass
elif action == "updated":
StripeCoupon.objects.filter(coupon_id=coupon_id, is_deleted=False).update(
Expand Down

0 comments on commit 8e55884

Please sign in to comment.