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

Copy forward when registering alias (fixes #10827) #10952

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ookiegajwa
Copy link

When flattening any command or registering an alias to a node with no direct children (such as a redirect), the code now takes into account any potential redirect/fork/forward on the target node. This fixes the issue where, when registering a command that was simply a redirect, only the namespaced literal would work, and not any aliases of the command.

This fixes #10827, and is now correctly based on a non-master branch :)

@ookiegajwa ookiegajwa requested a review from a team as a code owner June 21, 2024 23:38
@Owen1212055
Copy link
Member

Thanks for the PR! Looks good to me, not sure why that wasn’t originally done… that bit of code was missing some logic previously :P

@kennytv kennytv added the priority: high This issue is either a gamebreaking bug or crash and needs to be addressed soon. label Jun 22, 2024
@kennytv kennytv force-pushed the fix/brigadier-redirects branch 2 times, most recently from 6f74e5f to 53345db Compare July 15, 2024 19:54
When flattening any command or registering an alias to a node with no direct children (such as a redirect), the code now takes into account any potential redirect/fork/forward on the target node. This fixes the issue where, when registering a command that was simply a redirect, only the namespaced literal would work, and not any aliases of the command.
@ookiegajwa
Copy link
Author

Rebased to 1.21.1, tested again, still works :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: high This issue is either a gamebreaking bug or crash and needs to be addressed soon.
Projects
Status: Awaiting final testing
Development

Successfully merging this pull request may close these issues.

Redirect with brigadier API does not work as expected
3 participants