Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Fixed a bug where if a subscription had a trial end of none, that the… #369
Update subscription code would crash on charge_immediately when trial_period was set to NULL in database (None). This would happen if there were plans with trial periods mixed with plans that do not have trial periods.
What's this PR do?
Makes sure the trial period is not 'None' before attempting a time comparison between trial_end and timezone.now()
Any background context you want to provide?
This happens when you try to 'charge_immediately' on a plan with no trial period, or no trial period plan was initially selected.
What ticket or issue # does this fix?
Definition of Done (check if considered and/or addressed):