pull/11/head
TheCodedProf 3 years ago
parent 8a8dbdfea8
commit 4e0b325fe2

@ -224,7 +224,7 @@ export const callback = async (interaction: CommandInteraction): Promise<void> =
}
}
} else if(i.isStringSelectMenu()) {
await i.deferUpdate();
try {await i.deferUpdate();} catch (err) {}
switch(i.customId) {
case "color": {
data.color = colors[i.values[0]!]!;

@ -20,8 +20,8 @@ const command = (builder: SlashCommandSubcommandBuilder) =>
const callback = async (interaction: CommandInteraction): Promise<unknown> => {
if (!interaction.guild) return;
const name = interaction.options.get("name")?.value as string;
const value = interaction.options.get("value")?.value as string;
const newname = interaction.options.get("newname")?.value as string;
const value = interaction.options.get("value")?.value as string ?? "";
const newname = interaction.options.get("newname")?.value as string ?? "";
if (!newname && !value)
return await interaction.reply({
embeds: [

Loading…
Cancel
Save