3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-03-14 21:31:50 +00:00

Change nickname storage to the intended 10

This commit is contained in:
Dark 2020-07-29 01:58:28 +02:00
parent b8c75a922a
commit cd45d929ad

View file

@ -2,7 +2,6 @@ import { BaseGuildRepository } from "./BaseGuildRepository";
import { getRepository, In, Repository } from "typeorm";
import { NicknameHistoryEntry } from "./entities/NicknameHistoryEntry";
import { MINUTES, SECONDS } from "../utils";
import { MAX_USERNAME_ENTRIES_PER_USER } from "./UsernameHistory";
import { isAPI } from "../globals";
import { cleanupNicknames } from "./cleanup/nicknames";
@ -65,7 +64,7 @@ export class GuildNicknameHistory extends BaseGuildRepository {
.where("guild_id = :guildId", { guildId: this.guildId })
.andWhere("user_id = :userId", { userId })
.orderBy("id", "DESC")
.skip(MAX_USERNAME_ENTRIES_PER_USER)
.skip(MAX_NICKNAME_ENTRIES_PER_USER)
.take(99_999)
.getMany();