update ping

This commit is contained in:
SowinskiBraeden committed 2022-07-31 17:06:12 -07:00
1 parent 0776cb6974
commit ee3f38f6b6
2 files changed
+13 -4

No files matched your search

+3 -2
View File
@@ -28,6 +28,7 @@ class QuarksBot extends Client {
this.Ready = false;
this.ws.on("INTERACTION_CREATE", async (interaction) => {
const start = new Date().getTime();
if (interaction.type!=3) {
client.log("Interaction")
let GuildDB = await this.GetGuild(interaction.guild_id);
@@ -53,8 +54,8 @@ class QuarksBot extends Client {
});
};
let cmd = client.commands.get(command);
if (cmd.SlashCommand && cmd.SlashCommand.run)
cmd.SlashCommand.run(this, interaction, args, { GuildDB });
if (cmd.name == 'ping' && cmd.SlashCommand && cmd.SlashCommand.run) cmd.SlashCommand.run(this, interaction, args, { GuildDB }, start);
else if (cmd.SlashCommand && cmd.SlashCommand.run) cmd.SlashCommand.run(this, interaction, args, { GuildDB });
}
});