3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-17 23:25:02 +00:00

Add case_id to mutes. Add !mutes command to list mutes.

This commit is contained in:
Dragory 2018-08-05 00:18:50 +03:00
parent 128ae87b41
commit 3991858511
9 changed files with 131 additions and 3 deletions

View file

@ -9,6 +9,14 @@ export class GuildCases {
this.guildId = guildId;
}
async get(ids: number[]): Promise<Case[]> {
const result = await knex("cases")
.whereIn("id", ids)
.select();
return result.map(r => new Case(r));
}
async find(id: number): Promise<Case> {
const result = await knex("cases")
.where("guild_id", this.guildId)