koa-ratelimit: Missing support for ioredis (#44080)

This commit is contained in:
Oliver Salzburg 2020-04-26 18:30:44 +02:00 committed by GitHub
parent 410945551d
commit 7ddd7b45d2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -7,6 +7,7 @@
import { Middleware, Context } from "koa";
import { RedisClient } from "redis";
import { Redis } from "ioredis";
declare function KoaRatelimit(options?: KoaRatelimit.MiddlewareOptions): Middleware;
@ -37,7 +38,7 @@ declare namespace KoaRatelimit {
/**
* The database powering the backing rate-limiter package.
*/
db: RedisClient | Map<any, any>;
db: Redis | RedisClient | Map<any, any>;
/**
* The length of a single limiting period. This value is expressed