From e13bdc31272f382773a65508ab7bb5626d1c535e Mon Sep 17 00:00:00 2001 From: Flam3rboy <34555296+Flam3rboy@users.noreply.github.com> Date: Wed, 30 Jun 2021 17:49:19 +0200 Subject: :sparkles: RateLimit Bucket --- src/models/RateLimit.ts | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/models/RateLimit.ts b/src/models/RateLimit.ts index 7e4ca3cc..6ccfafe0 100644 --- a/src/models/RateLimit.ts +++ b/src/models/RateLimit.ts @@ -9,6 +9,7 @@ export interface Bucket { user: string; hits: number; blocked: boolean; + created_at: Date; } export interface BucketDocument extends Bucket, Document { @@ -20,6 +21,7 @@ export const BucketSchema = new Schema({ user_id: { type: String, required: true }, // bot, user, oauth_application, webhook hits: { type: Number, required: true }, // Number of times the user hit this bucket blocked: { type: Boolean, required: true }, + created_at: { type: Date, required: true }, }); // @ts-ignore -- cgit 1.4.1