Skip to content

Commit 11d82a6

Browse files
committed
log usage of rate limiter
1 parent 4ff4331 commit 11d82a6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

worker/trpc/middlewares/rate-limit.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ export const rateLimit = t.middleware(async ({ next, ctx }) => {
2121
throw new TRPCError({ code: "BAD_REQUEST", message: "IP address not found" });
2222
}
2323

24+
console.info("⏲️ Using Rate Limiter")
25+
2426
const { success } = await limiter.limit(ip);
2527
if (!success) {
2628
throw new TRPCError({

0 commit comments

Comments
 (0)