Need import for app to instantied correct app instances

drew/tilt-local-dev
Drew Bednar 2 years ago
parent 1442af6828
commit 07d716749e

@ -60,6 +60,8 @@ def add_user(username="", email=""):
from project.database import SessionLocal
from project.users.models import User
from main import app # pylint: disable=unused-import
session = SessionLocal()
user = User(username=username, email=email)
session.add(user)

Loading…
Cancel
Save