Skip to content

Commit

Permalink
fix: some commands do not work properly
Browse files Browse the repository at this point in the history
  • Loading branch information
MotiCAT committed Oct 4, 2023
1 parent b0925b5 commit 3ddb2ad
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/commands/ban.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = {
const user = interaction.options.getUser('member');
const member = await interaction.guild.members.fetch(user.id);
if (!member) return interaction.reply({ embeds: [new EmbedBuilder().addFields({ name: 'Error', value: 'サーバー内に存在しないメンバーです。' }).setFooter({ text: 'CH Protect 0.0.1', iconURL: interaction.client.user.displayAvatarURL() }).setColor('#ff0000')], ephemeral: true });
member.timeout(time)
member.ban()
.then(() => {
interaction.reply({ embeds: [new EmbedBuilder().addFields({ name: 'Done.', value: '指定したメンバーをBANしました。' }).setFooter({ text: 'CH Protect 0.0.1', iconURL: interaction.client.user.displayAvatarURL() }).setColor('#3CB371')], ephemeral: true });
})
Expand Down
2 changes: 1 addition & 1 deletion src/commands/context_kick.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module.exports = {
async execute(interaction) {
const member = await interaction.guild.members.fetch(interaction.targetUser.id)
if (!member) return interaction.reply({ embeds: [new EmbedBuilder().addFields({ name: 'Error', value: 'サーバー内に存在しないメンバーです。' }).setColor('#ff0000').setFooter({ text: 'CH Protect 0.0.1', iconURL: interaction.client.user.displayAvatarURL() })] });
member.ban()
member.kick()
.then(() => {
interaction.reply({ embeds: [new EmbedBuilder().addFields({ name: 'Done.', value: '指定したメンバーを追放しました。' }).setFooter({ text: 'CH Protect 0.0.1', iconURL: interaction.client.user.displayAvatarURL() }).setColor('#3CB371')], ephemeral: true });
})
Expand Down
2 changes: 1 addition & 1 deletion src/commands/kick.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = {
const user = interaction.options.getUser('member');
const member = await interaction.guild.members.fetch(user.id);
if (!member) return interaction.reply({ embeds: [new EmbedBuilder().addFields({ name: 'Error', value: '存在しないメンバーです。' }).setFooter({ text: 'CH Protect 0.0.1', iconURL: interaction.client.user.displayAvatarURL() }).setColor('#ff0000')], ephemeral: true });
member.timeout(time)
member.kick()
.then(() => {
interaction.reply({ embeds: [new EmbedBuilder().addFields({ name: 'Done.', value: '指定したユーザーを追放しました。' }).setFooter({ text: 'CH Protect 0.0.1', iconURL: interaction.client.user.displayAvatarURL() }).setColor('#3CB371')], ephemeral: true });
})
Expand Down

0 comments on commit 3ddb2ad

Please sign in to comment.