fix issue when SECRET_KEY is not provided
This commit is contained in:
parent
ce1aec90a9
commit
71f0a11789
|
@ -51,7 +51,7 @@ if not logo_folder.exists():
|
|||
username = os.environ.get("TGINDEX_USERNAME", "")
|
||||
password = os.environ.get("PASSWORD", "")
|
||||
SHORT_URL_LEN = int(os.environ.get("SHORT_URL_LEN", 3))
|
||||
authenticated = username and password
|
||||
authenticated = bool(username and password)
|
||||
SESSION_COOKIE_LIFETIME = int(os.environ.get("SESSION_COOKIE_LIFETIME") or "60")
|
||||
try:
|
||||
SECRET_KEY = os.environ["SECRET_KEY"]
|
||||
|
|
Loading…
Reference in New Issue