diff --git a/redash/handlers/authentication.py b/redash/handlers/authentication.py index 3e1c6955671..c19b7d175e3 100644 --- a/redash/handlers/authentication.py +++ b/redash/handlers/authentication.py @@ -93,9 +93,9 @@ def forgot_password(org_slug=None): def login(org_slug=None): # We intentionally use == as otherwise it won't actually use the proxy. So weird :O # noinspection PyComparisonWithNone - if current_org is None and not settings.MULTI_ORG: + if current_org == None and not settings.MULTI_ORG: return redirect('/setup') - elif current_org is None: + elif current_org == None: return redirect('/') index_url = url_for("redash.index", org_slug=org_slug) diff --git a/redash/handlers/setup.py b/redash/handlers/setup.py index 086541acb2d..2e376246e81 100644 --- a/redash/handlers/setup.py +++ b/redash/handlers/setup.py @@ -38,7 +38,7 @@ def create_org(org_name, user_name, email, password): @routes.route('/setup', methods=['GET', 'POST']) def setup(): - if current_org is not None or settings.MULTI_ORG: + if current_org != None or settings.MULTI_ORG: return redirect('/') form = SetupForm(request.form)