From ec0eeae074545d41cbe385c4ec459ecdee263c7b Mon Sep 17 00:00:00 2001 From: mat Date: Tue, 13 Dec 2022 21:20:04 -0600 Subject: Revert "ok what if i made the header x-key instead" This reverts commit af5858ba00aeef20e3b4c53b5baba641284eca72. --- src/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/index.ts b/src/index.ts index b249720..298dee3 100644 --- a/src/index.ts +++ b/src/index.ts @@ -20,7 +20,7 @@ const limiter = rateLimit({ max: 200, skip: (req: express.Request) => { console.log(req.headers) - return req.headers['x-key'] === process.env.key + return req.headers.key === process.env.key }, keyGenerator: (req: express.Request) => { return (req.headers['cf-connecting-ip'] ?? req.ip).toString() -- cgit