diff options
author | mat <github@matdoes.dev> | 2022-12-13 21:15:40 -0600 |
---|---|---|
committer | mat <github@matdoes.dev> | 2022-12-13 21:15:40 -0600 |
commit | af5858ba00aeef20e3b4c53b5baba641284eca72 (patch) | |
tree | 4b627e45af63a7ee28c97053ee721f9a101e449a /src/index.ts | |
parent | 1b5036220b09c9de50a5bb55852ad2bcc370a6f4 (diff) | |
download | skyblock-api-af5858ba00aeef20e3b4c53b5baba641284eca72.tar.gz skyblock-api-af5858ba00aeef20e3b4c53b5baba641284eca72.tar.bz2 skyblock-api-af5858ba00aeef20e3b4c53b5baba641284eca72.zip |
ok what if i made the header x-key instead
Diffstat (limited to 'src/index.ts')
-rw-r--r-- | src/index.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/index.ts b/src/index.ts index 298dee3..b249720 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.key === process.env.key + return req.headers['x-key'] === process.env.key }, keyGenerator: (req: express.Request) => { return (req.headers['cf-connecting-ip'] ?? req.ip).toString() |