From 7d944c1d4a39bdd50d9de0c51b72f2e4bc465b9f Mon Sep 17 00:00:00 2001 From: Rachel Lambda Samuelsson Date: Sat, 4 May 2024 14:12:38 +0200 Subject: [PATCH] =?UTF-8?q?l=C3=A4gg=20till=20app=20context=20s=C3=A5=20at?= =?UTF-8?q?t=20db=20operationer=20inte=20krashar?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/tv.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/tv.py b/src/tv.py index 4f3cda2..fdac162 100644 --- a/src/tv.py +++ b/src/tv.py @@ -10,6 +10,8 @@ app = Flask(__name__) app.config.from_object(config) +app.app_context().push() + db = SQLAlchemy(app) db.create_all()