-
-
Notifications
You must be signed in to change notification settings - Fork 315
Open
Labels
commandsFor issues related to DSharpPlus.CommandsFor issues related to DSharpPlus.Commands
Milestone
Description
Summary
The localization feature is not working with UserCommands and MessageCommands processors. Tested without the localizer, the commands work. The localizer work with any other SlashCommands, so it seems that both UserCommands and MessageCommands does not implement the localization feature.
What version of the library are you using?
v5.0.0-nightly (make sure you are using the latest nightly!)
What .NET version are you using? Make sure to use the latest patch release for your major version.
.NET 9.0
Operating System
No response
Reproduction Steps
- Create a UserCommand and MessageCommand without localization, they work.
- Add the InteractionLocalizer attribute with a working implementation of a localizer to them: The commands no longer work and both spit a NRE.
Trace Logs
Exceptions or other error messages
System.NullReferenceException: Object reference not set to an instance of an object.
at DSharpPlus.Commands.Processors.SlashCommands.SlashCommandProcessor.ExecuteLocalizerAsync(Type localizer, String name)
at DSharpPlus.Commands.Processors.UserCommands.UserCommandProcessor.ToApplicationCommandAsync(Command command)
at DSharpPlus.Commands.Processors.UserCommands.UserCommandProcessor.ConfigureAsync(CommandsExtension extension)
at DSharpPlus.Commands.CommandsExtension.RefreshAsync()
at DSharpPlus.Commands.RefreshEventHandler.HandleEventAsync(DiscordClient sender, ClientStartedEventArgs eventArgs)
at DSharpPlus.Clients.DefaultEventDispatcher.<>c__DisplayClass6_0`1.<<DispatchAsync>b__0>d.MoveNext()
Anything else you'd like to share
No response
Metadata
Metadata
Assignees
Labels
commandsFor issues related to DSharpPlus.CommandsFor issues related to DSharpPlus.Commands