fix: not sending trial ending for user having lifetime licence

This commit is contained in:
Son NK 2020-02-10 21:43:59 +07:00
parent 6ad395f24f
commit c00fdd6cfb
1 changed files with 1 additions and 1 deletions

View File

@ -20,7 +20,7 @@ from server import create_app
def notify_trial_end():
for user in User.query.filter(
User.activated == True, User.trial_end.isnot(None)
User.activated == True, User.trial_end.isnot(None), User.lifetime == False
).all():
if arrow.now().shift(days=3) > user.trial_end >= arrow.now().shift(days=2):
LOG.d("Send trial end email to user %s", user)