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 potential NPEs in PlotGroup #7483

Merged
merged 1 commit into from
Jun 26, 2024

Conversation

galacticwarrior9
Copy link
Contributor

@galacticwarrior9 galacticwarrior9 commented Jun 26, 2024

Description:

This PR adds a null check to PlotGroup#getTownBlocks and PlotGroup#hasTownBlock like the other methods in the class. This fixes these methods throwing NPEs if the townBlocks field has not yet been initialised.


New Nodes/Commands/ConfigOptions:


Relevant Towny Issue ticket:


  • I have tested this pull request for defects on a server.

By making this pull request, I represent that I have the right to waive copyright and related rights to my contribution, and agree that all copyright and related rights in my contributions are waived, and I acknowledge that the TownyAdvanced organization has the copyright to use and modify my contribution under the Towny License for perpetuity.

@LlmDl LlmDl changed the title Fix NPEs in PlotGroup Fix potential NPEs in PlotGroup Jun 26, 2024
@LlmDl LlmDl added this to the 0.100.4.0 milestone Jun 26, 2024
@LlmDl LlmDl merged commit 0eda250 into TownyAdvanced:master Jun 26, 2024
1 check passed
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.

2 participants