bug fixes/remove tweet channel
This commit is contained in:
6 files changed
+137
-50
No files matched your search
+27
-25
@@ -27,32 +27,34 @@ class QuarksBot extends Client {
|
||||
this.Ready = false;
|
||||
|
||||
this.ws.on("INTERACTION_CREATE", async (interaction) => {
|
||||
client.log("Interaction")
|
||||
let GuildDB = await this.GetGuild(interaction.guild_id);
|
||||
|
||||
const command = interaction.data.name.toLowerCase();
|
||||
const args = interaction.data.options;
|
||||
if (interaction.type!=3) {
|
||||
client.log("Interaction")
|
||||
let GuildDB = await this.GetGuild(interaction.guild_id);
|
||||
|
||||
//Easy to send respnose so ;)
|
||||
interaction.guild = await this.guilds.fetch(interaction.guild_id);
|
||||
interaction.send = async (message) => {
|
||||
return await this.api
|
||||
.interactions(interaction.id, interaction.token)
|
||||
.callback.post({
|
||||
data: {
|
||||
type: 4,
|
||||
data:
|
||||
typeof message == "string"
|
||||
? { content: message }
|
||||
: message.type && message.type === "rich"
|
||||
? { embeds: [message] }
|
||||
: message,
|
||||
},
|
||||
});
|
||||
};
|
||||
let cmd = client.commands.get(command);
|
||||
if (cmd.SlashCommand && cmd.SlashCommand.run)
|
||||
cmd.SlashCommand.run(this, interaction, args, { GuildDB });
|
||||
const command = interaction.data.name.toLowerCase();
|
||||
const args = interaction.data.options;
|
||||
|
||||
//Easy to send respnose so ;)
|
||||
interaction.guild = await this.guilds.fetch(interaction.guild_id);
|
||||
interaction.send = async (message) => {
|
||||
return await this.api
|
||||
.interactions(interaction.id, interaction.token)
|
||||
.callback.post({
|
||||
data: {
|
||||
type: 4,
|
||||
data:
|
||||
typeof message == "string"
|
||||
? { content: message }
|
||||
: message.type && message.type === "rich"
|
||||
? { embeds: [message] }
|
||||
: message,
|
||||
},
|
||||
});
|
||||
};
|
||||
let cmd = client.commands.get(command);
|
||||
if (cmd.SlashCommand && cmd.SlashCommand.run)
|
||||
cmd.SlashCommand.run(this, interaction, args, { GuildDB });
|
||||
}
|
||||
});
|
||||
|
||||
const client = this;
|
||||
|
||||
Reference in new issue
Block a user