bug fixes
This commit is contained in:
parent
6b88aff1e7
commit
4b8fa012da
3 changed files with 11 additions and 3 deletions
|
|
@ -16,9 +16,11 @@ limitations under the License.
|
||||||
|
|
||||||
import { SlashCommandOptionsOnlyBuilder } from 'discord.js';
|
import { SlashCommandOptionsOnlyBuilder } from 'discord.js';
|
||||||
import yroo from './commands/yroo';
|
import yroo from './commands/yroo';
|
||||||
|
import wiki from './commands/wiki';
|
||||||
|
|
||||||
const commandList = [
|
const commandList = [
|
||||||
yroo
|
yroo,
|
||||||
|
wiki
|
||||||
];
|
];
|
||||||
|
|
||||||
export default commandList;
|
export default commandList;
|
||||||
|
|
|
||||||
|
|
@ -48,3 +48,5 @@ async function execute (interaction: ChatInputCommandInteraction) {
|
||||||
embeds: [pageEmbed]
|
embeds: [pageEmbed]
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export default { data, execute };
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,11 @@ for (let command of commandList) {
|
||||||
commands.push(command.data.toJSON());
|
commands.push(command.data.toJSON());
|
||||||
}
|
}
|
||||||
|
|
||||||
const guilds = process.env.GUILD_IDS.trim().split(/[\s,;]+/);
|
if (process.env.GUILD_IDS === void 0){
|
||||||
|
console.warn('GUILD_IDS not set, registering commands globally');
|
||||||
|
}
|
||||||
|
|
||||||
|
const guilds = (process.env.GUILD_IDS ?? '').trim().split(/[\s,;]+/);
|
||||||
|
|
||||||
const rest = new REST({ version: '10' }).setToken(process.env.TOKEN);
|
const rest = new REST({ version: '10' }).setToken(process.env.TOKEN);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue