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

Fix keyboard navigation crash #814

Merged
merged 1 commit into from
Jan 6, 2025
Merged

Conversation

Dev0Louis
Copy link
Contributor

As of 1.21.4 the parameter of the method setSelected is Nullable.
Without this PR trying to press arrow down while having the last mod entry selected will result in the game crashing.
Null means that we have exhausted the list, so I set the selectedModId to null as is done on class initialization when no mod is selected.

As far as I could tell this restores the behavior of old versions.

@Prospector Prospector merged commit b60199e into TerraformersMC:1.21.4 Jan 6, 2025
1 check passed
@Prospector
Copy link
Member

thanks!

@haykam821 haykam821 added the bug A problem with the project label Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A problem with the project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants