forked from Galactic/galactic-bot
move handle call
This commit is contained in:
parent
0a2a37f23e
commit
e905d766f8
@ -55,8 +55,6 @@ class BanInfraction extends Infraction
|
|||||||
if (callbacks.size > 0)
|
if (callbacks.size > 0)
|
||||||
callbacks.map((c) => this.client.moderation.removeCallback(c.infraction, true));
|
callbacks.map((c) => this.client.moderation.removeCallback(c.infraction, true));
|
||||||
|
|
||||||
await this.handle();
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
await this.guild.members.ban(this.target!.id, {
|
await this.guild.members.ban(this.target!.id, {
|
||||||
@ -68,6 +66,7 @@ class BanInfraction extends Infraction
|
|||||||
{
|
{
|
||||||
return this._fail('INFRACTION_ERROR');
|
return this._fail('INFRACTION_ERROR');
|
||||||
}
|
}
|
||||||
|
await this.handle();
|
||||||
return this._succeed();
|
return this._succeed();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -50,8 +50,6 @@ class KickInfraction extends Infraction
|
|||||||
|
|
||||||
async execute ()
|
async execute ()
|
||||||
{
|
{
|
||||||
await this.handle();
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
await this.member!.kick(this._reason);
|
await this.member!.kick(this._reason);
|
||||||
@ -60,6 +58,7 @@ class KickInfraction extends Infraction
|
|||||||
{
|
{
|
||||||
return this._fail('INFRACTION_ERROR');
|
return this._fail('INFRACTION_ERROR');
|
||||||
}
|
}
|
||||||
|
await this.handle();
|
||||||
return this._succeed();
|
return this._succeed();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -47,7 +47,6 @@ class SoftbanInfraction extends Infraction
|
|||||||
let days = 1;
|
let days = 1;
|
||||||
if (this.arguments.days)
|
if (this.arguments.days)
|
||||||
days = this.arguments.days.asNumber;
|
days = this.arguments.days.asNumber;
|
||||||
await this.handle();
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
@ -61,6 +60,7 @@ class SoftbanInfraction extends Infraction
|
|||||||
{
|
{
|
||||||
return this._fail('INFRACTION_ERROR');
|
return this._fail('INFRACTION_ERROR');
|
||||||
}
|
}
|
||||||
|
await this.handle();
|
||||||
return this._succeed();
|
return this._succeed();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user