From 7c19b3f3247aa5b3e46cac750194874ffef0cafd Mon Sep 17 00:00:00 2001 From: nexy7574 Date: Fri, 19 Apr 2024 11:01:48 +0100 Subject: [PATCH] use lifespan --- ipserv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ipserv.py b/ipserv.py index c1f789e..75ab152 100644 --- a/ipserv.py +++ b/ipserv.py @@ -20,7 +20,7 @@ async def lifespan(_app: FastAPI): yield -app = FastAPI() +app = FastAPI(lifespan=lifespan) app.state.cache = {}