secure media endpoints
This commit is contained in:
@@ -12,8 +12,10 @@ engine = create_engine(SQLALCHEMY_DATABASE_URL)
|
||||
SessionLocal = sessionmaker(bind=engine)
|
||||
|
||||
|
||||
def get_db() -> Generator:
|
||||
def get_db() -> Generator[Session, None, None]:
|
||||
""" """
|
||||
with SessionLocal() as db:
|
||||
yield db
|
||||
|
||||
SessionDep: type[Session] = Annotated[Session, Depends(get_db)]
|
||||
|
||||
SessionDep = Annotated[Session, Depends(get_db)]
|
||||
|
||||
Reference in New Issue
Block a user