From cea1634d937d1eaff815490a82bbe3ba803070b1 Mon Sep 17 00:00:00 2001 From: Andrey Date: Wed, 29 Mar 2017 18:46:34 +0300 Subject: [PATCH] license: better variable name --- project/customer/utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/project/customer/utils.py b/project/customer/utils.py index 633aa75..d1231c4 100644 --- a/project/customer/utils.py +++ b/project/customer/utils.py @@ -12,7 +12,7 @@ SUPPORT_EMAIL = getattr(settings, 'SUPPORT_EMAIL') def check_one_profile(profile, License, now_, manual=False): - profile_is_active = profile.active + profile_was_active = profile.active licenses = License.objects.filter(company=profile, date_from__lte=now_, date_to__gte=now_, status__in=[consts.LICENSE_TEST_PERIOD, consts.LICENSE_PAID, consts.LICENSE_ACTIVE], deleted=False) @@ -27,7 +27,7 @@ def check_one_profile(profile, License, now_, manual=False): user_email = profile.users.get().email - if profile.active and not profile_is_active: + if profile.active and not profile_was_active: template_name = 'myauth/license_activated.txt' subject = u'Документор: Профиль активирован' dict_context = {