fix(discord): declare slash commands on module methods
PR Checks / test-and-build (pull_request) Successful in 8m26s

This commit is contained in:
2026-05-25 16:27:29 +03:00
parent 80e346d6b5
commit 0b45aee96d
9 changed files with 53 additions and 16 deletions
@@ -4,7 +4,6 @@ using NetCord.Services.ApplicationCommands;
namespace GmRelay.DiscordBot.Features.Sessions;
[SlashCommand("newsession", "Create a new game session")]
public class DiscordNewSessionCommand : ApplicationCommandModule<SlashCommandContext>
{
private readonly DiscordNewSessionHandler _handler;
@@ -16,6 +15,7 @@ public class DiscordNewSessionCommand : ApplicationCommandModule<SlashCommandCon
_logger = logger;
}
[SlashCommand("newsession", "Create a new game session")]
public async Task ExecuteAsync(
[SlashCommandParameter(Name = "title", Description = "Game title")] string title,
[SlashCommandParameter(Name = "time", Description = "Session time (YYYY-MM-DD HH:mm or DD.MM.YYYY HH:mm)")] string time,