Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed first level subcommand registration #4

Merged
merged 1 commit into from
Jun 28, 2024
Merged

Conversation

Plytas
Copy link
Owner

@Plytas Plytas commented Jun 28, 2024

This PR fixes first level subcommand registration:

DiscordCommandRegistry::setCommands([
    'test' => [
        'command' => TestCommand::class,
    ],
]);

Previously, it would incorrectly register TestCommand as sub command group even though it's the last in the chain. Now it will correctly handle these cases and register them as sub commands.

@Plytas Plytas self-assigned this Jun 28, 2024
@Plytas Plytas merged commit b4c34de into main Jun 28, 2024
11 checks passed
@Plytas Plytas deleted the command-registration branch June 28, 2024 12:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant