diff --git a/fastapi_template/template/{{cookiecutter.project_name}}/{{cookiecutter.project_name}}/web/lifetime.py b/fastapi_template/template/{{cookiecutter.project_name}}/{{cookiecutter.project_name}}/web/lifetime.py index d3e5bdd..34f2d6a 100644 --- a/fastapi_template/template/{{cookiecutter.project_name}}/{{cookiecutter.project_name}}/web/lifetime.py +++ b/fastapi_template/template/{{cookiecutter.project_name}}/{{cookiecutter.project_name}}/web/lifetime.py @@ -35,11 +35,11 @@ {%- if cookiecutter.orm == "ormar" %} -from {{cookiecutter.project_name}}.db.config import database +from {{cookiecutter.project_name}}.db.base import database {%- if cookiecutter.db_info.name != "none" and cookiecutter.enable_migrations != "True" %} from sqlalchemy.engine import create_engine -from {{cookiecutter.project_name}}.db.meta import meta +from {{cookiecutter.project_name}}.db.base import meta from {{cookiecutter.project_name}}.db.models import load_all_models {%- endif %}