Fix bug where unauthorized users could change llmconf lol

This commit is contained in:
James Shiffer 2024-07-31 04:46:43 +00:00
parent 4124be492d
commit c0d48a92dc

View File

@ -18,6 +18,7 @@ async function configCommand(interaction: ChatInputCommandInteraction)
{
if (interaction.user.id !== process.env.ADMIN) {
await interaction.reply("You are not authorized to change model settings");
return;
}
config.llmSettings.max_new_tokens = interaction.options.getInteger('max_new_tokens') ?? config.llmSettings.max_new_tokens;