From cbb53a528c9145761a62ebe16e4ac56e33758079 Mon Sep 17 00:00:00 2001 From: sumajoo <41197679+sumajoo@users.noreply.github.com> Date: Tue, 29 Jul 2025 16:33:22 +0200 Subject: [PATCH] Fix package path and minor issues --- package.json | 2 +- src/deploy-commands.js | 2 +- src/index.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 27676f4..d969c7c 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "version": "1.0.0", "type": "module", "description": "", - "main": "index.js", + "main": "src/index.js", "scripts": { "test": "NODE_ENV=test node --test test/*.test.js", "typecheck": "tsc --noEmit -p jsconfig.json" diff --git a/src/deploy-commands.js b/src/deploy-commands.js index ed75965..8ed6099 100644 --- a/src/deploy-commands.js +++ b/src/deploy-commands.js @@ -11,7 +11,7 @@ export async function deployCommands({ REST, Routes, SlashCommandBuilder }, log .setDescription('Erstelle einen aussagekräftigen Titel für das Issue') .setRequired(true)) .addStringOption(opt => opt.setName('beschreibung') - .setDescription('Beschreibe das Problem oder Feature ausführlich, beschriebe Schritte zum Reproduzieren.') + .setDescription('Beschreibe das Problem oder Feature ausführlich, beschreibe Schritte zum Reproduzieren.') .setRequired(false)) .toJSON(), ]; diff --git a/src/index.js b/src/index.js index c6ad3c2..7b74837 100644 --- a/src/index.js +++ b/src/index.js @@ -15,7 +15,7 @@ export async function handleIssueInteraction(interaction) { if (interaction.commandName !== 'issue') return; const title = interaction.options.getString('titel'); - const body = interaction.options.getString('beschreibung'); + const body = interaction.options.getString('beschreibung') ?? ''; await interaction.deferReply({ flags: MessageFlags.Ephemeral }); try { const { data } = await axios.post(`https://api.github.com/repos/${process.env.GITHUB_REPO}/issues`, {