From c7d1373020db67d99186c6befa2037456f11f78a Mon Sep 17 00:00:00 2001 From: yuuki <> Date: Sun, 2 Feb 2025 11:25:50 +0900 Subject: [PATCH] =?UTF-8?q?=E6=8A=95=E7=A8=BF=E5=88=B6=E9=99=90=E3=82=92?= =?UTF-8?q?=E8=A7=A3=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app.py b/app.py index 28511f9..5c54982 100644 --- a/app.py +++ b/app.py @@ -170,7 +170,7 @@ async def api_get(id: str = None): res.headers["CDN-Cache-Control"] = f"max-age=60" return res -@app.post("/api/litey/post", dependencies=[Depends(RateLimiter(times=4, seconds=3600))]) +@app.post("/api/litey/post") async def api_post(item: LiteYItem, req: Request): ctx["mongo_client"].litey.notes.insert_one({ "id": str(uuid4()), @@ -210,7 +210,7 @@ async def api_ng_get(): res.headers["CDN-Cache-Control"] = f"max-age=60" return res -@app.post("/api/ng/post", dependencies=[Depends(RateLimiter(times=4, seconds=3600))]) +@app.post("/api/ng/post") async def api_ng_post(item: NGItem): ctx["mongo_client"].litey.ngs.insert_one({ "word": item.word