From 691d3721e8e278312e82eebcfe19f31a4ebe6c35 Mon Sep 17 00:00:00 2001 From: SKairinos Date: Thu, 7 Nov 2024 13:21:39 +0000 Subject: [PATCH] fix: comment out check --- codeforlife/models/abstract_base_user.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/codeforlife/models/abstract_base_user.py b/codeforlife/models/abstract_base_user.py index 70aef6a..8c74a26 100644 --- a/codeforlife/models/abstract_base_user.py +++ b/codeforlife/models/abstract_base_user.py @@ -3,7 +3,7 @@ Created on 06/11/2024 at 16:38:15(+00:00). """ -import sys +# import sys import typing as t from functools import cached_property @@ -53,13 +53,14 @@ def _session_class(self): @property def is_authenticated(self): """A flag designating if this contributor has authenticated.""" + # TODO: delete if not needed. # Avoid initial migration error where session table is not created yet - if ( - sys.argv - and "manage.py" in sys.argv[0] - and "runserver" not in sys.argv - ): - return True + # if ( + # sys.argv + # and "manage.py" in sys.argv[0] + # and "runserver" not in sys.argv + # ): + # return True try: return self.is_active and not self.session.is_expired