diff --git a/kanken_online/__init__.py b/kanken_online/__init__.py index 0ee952b..480d9eb 100644 --- a/kanken_online/__init__.py +++ b/kanken_online/__init__.py @@ -41,7 +41,7 @@ def create_app(test_config=None): def update_settings(form): db = get_database() - if session["user_id"]: + if "user_id" in session: # Set values in the database settings = db.execute("SELECT * FROM user_settings WHERE user_id = ?", (session["user_id"],)