Skip to content

Commit

Permalink
Merge branch 'discounts' of github.com:otistamp/pinax-stripe
Browse files Browse the repository at this point in the history
  • Loading branch information
otistamp committed Mar 7, 2017
2 parents 433881f + 1800a9b commit dceb089
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pinax/stripe/actions/subscriptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,8 @@ def sync_subscription_from_stripe_data(customer, subscription):
)
sub = utils.update_with_defaults(sub, defaults, created)
if subscription.get("discount", None):
start = subscription["discount"]["start"]
end = subscription["discount"]["end"]
start = utils.convert_tstamp(subscription["discount"]["start"])
end = utils.convert_tstamp(subscription["discount"]["end"]) if subscription["discount"]["end"] else None
models.Discount.objects.get_or_create(subscription=sub, start=start, end=end)
return sub

Expand Down

0 comments on commit dceb089

Please sign in to comment.