mirror of
https://github.com/nx-bat/discordbot-ng.git
synced 2026-09-22 10:29:10 -04:00
Ban command
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
import { GuildBan } from 'discord.js';
|
||||
import { Database } from '../shared/Database';
|
||||
|
||||
export async function handleBanRemove(ban: GuildBan) {
|
||||
await Database.removeBan(ban.user.id);
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
import { Guild } from 'discord.js';
|
||||
import { Database } from '../shared/Database';
|
||||
|
||||
export async function handleGuildCreate(guild) {
|
||||
export async function handleGuildCreate(guild: Guild) {
|
||||
try {
|
||||
if (!await Database.getGuildSettings(guild.id)) await Database.putGuild(guild.id);
|
||||
} catch (e) {
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
export * from './handle-audit-log-create';
|
||||
export * from './handle-ban-remove';
|
||||
export * from './handle-guild-create';
|
||||
export * from './handle-member-join';
|
||||
export * from './handle-message';
|
||||
|
||||
Reference in New Issue
Block a user