Skip to content
Snippets Groups Projects
Verified Commit c403602e authored by Jonas Leder's avatar Jonas Leder
Browse files

fix page not working without login enabled

parent 81d20bfe
Branches
Tags
No related merge requests found
......@@ -7,6 +7,8 @@ def home(request, builddate, domain_prepared, recaptchaPublicKey, showDomainSele
loginbar = '<a href="/user/login?service=google">login</a>'
elif(loginType == "github"):
loginbar = '<a href="/user/login?service=github">login</a>'
else:
loginbar = ""
try:
prefilledDomain = domain_to_index[request.headers["host"]]
......
......@@ -67,6 +67,9 @@ try:
except:
host="127.0.0.1"
loginEnabled = False
loginType = ""
try:
if(environ["login"] == "github" or environ["login"] == "google"):
loginEnabled = True
......@@ -74,13 +77,8 @@ try:
loginType = environ["login"]
else:
loginEnabled = False
loginType = ""
else:
loginEnabled = False
loginType = ""
except:
loginEnabled = False
loginType = ""
pass
try:
if(environ["passwordToShort"] != ""):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment