diff --git a/project/customer/context_processors.py b/project/customer/context_processors.py index 8d6cafb..db8b58a 100644 --- a/project/customer/context_processors.py +++ b/project/customer/context_processors.py @@ -17,6 +17,13 @@ cache_duration = 3600 def license_check_soon_ends(request): + try: + # admins don't have profile + if not request.user.profile: + return { } + except AttributeError as e: + return { } + try: license_cookie = request.COOKIES.get('close_message_license') license_15days = cache.get('license_15_%s' % (request.user.username,), None)