mirror of
https://github.com/BobbyWibowo/lolisafe.git
synced 2024-12-14 08:26:22 +00:00
chore: RateLimiter clean ups
This commit is contained in:
parent
3ce3547d15
commit
9852dec3d1
@ -2,9 +2,10 @@ const { RateLimiterMemory } = require('rate-limiter-flexible')
|
|||||||
const ClientError = require('./../utils/ClientError')
|
const ClientError = require('./../utils/ClientError')
|
||||||
|
|
||||||
class RateLimiter {
|
class RateLimiter {
|
||||||
|
rateLimiterMemory
|
||||||
|
|
||||||
#requestKey
|
#requestKey
|
||||||
#whitelistedKeys
|
#whitelistedKeys
|
||||||
rateLimiterMemory
|
|
||||||
|
|
||||||
constructor (requestKey, options = {}, whitelistedKeys) {
|
constructor (requestKey, options = {}, whitelistedKeys) {
|
||||||
if (typeof options.points !== 'number' || typeof options.duration !== 'number') {
|
if (typeof options.points !== 'number' || typeof options.duration !== 'number') {
|
||||||
|
Loading…
Reference in New Issue
Block a user