aboutsummaryrefslogtreecommitdiff
path: root/src/lib/models/shared/MemberCount.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/models/shared/MemberCount.ts')
-rw-r--r--src/lib/models/shared/MemberCount.ts38
1 files changed, 0 insertions, 38 deletions
diff --git a/src/lib/models/shared/MemberCount.ts b/src/lib/models/shared/MemberCount.ts
deleted file mode 100644
index ea8795c..0000000
--- a/src/lib/models/shared/MemberCount.ts
+++ /dev/null
@@ -1,38 +0,0 @@
-import { type Sequelize } from 'sequelize';
-const { DataTypes, Model } = (await import('sequelize')).default;
-
-export interface MemberCountModel {
- timestamp: Date;
- guildId: string;
- memberCount: number;
-}
-
-export interface MemberCountCreationAttributes {
- timestamp?: Date;
- guildId: string;
- memberCount: number;
-}
-
-/**
- * The member count of each guild that the bot is in that have over 100 members.
- */
-export class MemberCount extends Model<MemberCountModel, MemberCountCreationAttributes> implements MemberCountModel {
- public declare timestamp: Date;
- public declare guildId: string;
- public declare memberCount: number;
-
- /**
- * Initializes the model.
- * @param sequelize The sequelize instance.
- */
- public static initModel(sequelize: Sequelize): void {
- MemberCount.init(
- {
- timestamp: { type: DataTypes.DATE, allowNull: false, defaultValue: DataTypes.NOW },
- guildId: { type: DataTypes.STRING, allowNull: false },
- memberCount: { type: DataTypes.BIGINT, allowNull: false }
- },
- { sequelize, timestamps: false }
- );
- }
-}