final ORJSONResponse

This commit is contained in:
s.mostryukov 2024-07-12 14:49:52 +03:00
parent 3b175a1f83
commit 3e099c9263
1 changed files with 2 additions and 0 deletions

View File

@ -7,6 +7,7 @@ from api import router as api_router
import uvicorn
from fastapi import FastAPI
from fastapi.responses import ORJSONResponse
@asynccontextmanager
async def lifespan(app: FastAPI):
@ -14,6 +15,7 @@ async def lifespan(app: FastAPI):
await db_helper.dispose()
main_app = FastAPI(
default_response_class=ORJSONResponse,
lifespan=lifespan,
)