Update bot to discord.js v13 (#125)
* Update bot to discord.js v13 * Remove debug code
This commit is contained in:
parent
2ca9a40458
commit
39c06fbc8e
22 changed files with 125 additions and 92 deletions
|
@ -4,7 +4,7 @@ import { ICommandContext } from "../../contracts/ICommandContext";
|
|||
export default class ErrorEmbed extends MessageEmbed {
|
||||
public context: ICommandContext;
|
||||
|
||||
constructor(context: ICommandContext, message: String) {
|
||||
constructor(context: ICommandContext, message: string) {
|
||||
super();
|
||||
|
||||
super.setColor(0xd52803);
|
||||
|
@ -14,6 +14,6 @@ export default class ErrorEmbed extends MessageEmbed {
|
|||
}
|
||||
|
||||
public SendToCurrentChannel() {
|
||||
this.context.message.channel.send(this);
|
||||
this.context.message.channel.send({ embeds: [ this ]});
|
||||
}
|
||||
}
|
|
@ -23,7 +23,7 @@ export default class EventEmbed extends MessageEmbed {
|
|||
}
|
||||
}
|
||||
|
||||
public AddReason(message: String) {
|
||||
public AddReason(message: string) {
|
||||
this.addField("Reason", message || "*none*");
|
||||
}
|
||||
|
||||
|
@ -37,7 +37,7 @@ export default class EventEmbed extends MessageEmbed {
|
|||
return;
|
||||
}
|
||||
|
||||
channel.send(this);
|
||||
channel.send({embeds: [ this ]});
|
||||
}
|
||||
|
||||
public async SendToMessageLogsChannel() {
|
||||
|
|
|
@ -25,13 +25,13 @@ export default class LogEmbed extends MessageEmbed {
|
|||
}
|
||||
}
|
||||
|
||||
public AddReason(message: String) {
|
||||
public AddReason(message: string) {
|
||||
this.addField("Reason", message || "*none*");
|
||||
}
|
||||
|
||||
// Send methods
|
||||
public SendToCurrentChannel() {
|
||||
this.context.message.channel.send(this);
|
||||
this.context.message.channel.send({ embeds: [ this ]});
|
||||
}
|
||||
|
||||
public SendToChannel(name: string) {
|
||||
|
@ -44,7 +44,7 @@ export default class LogEmbed extends MessageEmbed {
|
|||
return;
|
||||
}
|
||||
|
||||
channel.send(this);
|
||||
channel.send({ embeds: [ this ]});
|
||||
}
|
||||
|
||||
public async SendToMessageLogsChannel() {
|
||||
|
|
|
@ -15,12 +15,12 @@ export default class PublicEmbed extends MessageEmbed {
|
|||
}
|
||||
|
||||
// Detail methods
|
||||
public AddReason(message: String) {
|
||||
public AddReason(message: string) {
|
||||
this.addField("Reason", message || "*none*");
|
||||
}
|
||||
|
||||
// Send methods
|
||||
public SendToCurrentChannel() {
|
||||
this.context.message.channel.send(this);
|
||||
this.context.message.channel.send({ embeds: [ this ]});
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue