diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-09-05 21:45:29 -0400 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-09-05 21:45:29 -0400 |
commit | e3c116e0f4b741032fe777936fdf5d80f0b011e6 (patch) | |
tree | 024bd9884f1456983faae2b62b59485a879ac934 /src/lib/models | |
parent | c8a5bfe694ee6e784a0c5cbe1a7076b1c055249a (diff) | |
download | tanzanite-e3c116e0f4b741032fe777936fdf5d80f0b011e6.tar.gz tanzanite-e3c116e0f4b741032fe777936fdf5d80f0b011e6.tar.bz2 tanzanite-e3c116e0f4b741032fe777936fdf5d80f0b011e6.zip |
modlogid uuid -> nanoid
Diffstat (limited to 'src/lib/models')
-rw-r--r-- | src/lib/models/ActivePunishment.ts | 6 | ||||
-rw-r--r-- | src/lib/models/ModLog.ts | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/models/ActivePunishment.ts b/src/lib/models/ActivePunishment.ts index 794560f..f453426 100644 --- a/src/lib/models/ActivePunishment.ts +++ b/src/lib/models/ActivePunishment.ts @@ -1,6 +1,6 @@ import { Snowflake } from 'discord.js'; +import { nanoid } from 'nanoid'; import { DataTypes, Sequelize } from 'sequelize'; -import { v4 as uuidv4 } from 'uuid'; import { BaseModel } from './BaseModel'; export enum ActivePunishmentType { @@ -26,7 +26,7 @@ export interface ActivePunishmentModelCreationAttributes { guild: Snowflake; extraInfo?: Snowflake; expires?: Date; - modlog?: string; + modlog: string; } const NEVER_USED = 'This should never be executed'; @@ -112,7 +112,7 @@ export class ActivePunishment type: DataTypes.STRING, primaryKey: true, allowNull: false, - defaultValue: uuidv4 + defaultValue: nanoid }, type: { type: DataTypes.STRING, diff --git a/src/lib/models/ModLog.ts b/src/lib/models/ModLog.ts index 5c87331..a70913d 100644 --- a/src/lib/models/ModLog.ts +++ b/src/lib/models/ModLog.ts @@ -1,6 +1,6 @@ import { Snowflake } from 'discord.js'; +import { nanoid } from 'nanoid'; import { DataTypes, Sequelize } from 'sequelize'; -import { v4 as uuidv4 } from 'uuid'; import { BaseModel } from './BaseModel'; import { jsonParseGet, jsonParseSet, NEVER_USED } from './__helpers'; @@ -155,7 +155,7 @@ export class ModLog extends BaseModel<ModLogModel, ModLogModelCreationAttributes type: DataTypes.STRING, primaryKey: true, allowNull: false, - defaultValue: uuidv4 + defaultValue: nanoid }, type: { type: DataTypes.STRING, //# This is not an enum because of a sequelize issue: https://github.com/sequelize/sequelize/issues/2554 |