Skip to content

refactor: replace commons-lang Validate with Guava Preconditions (#3586)#4353

Open
Gteeri wants to merge 2 commits into
Slimefun:experimentalfrom
Gteeri:fix/replace-validate-with-preconditions
Open

refactor: replace commons-lang Validate with Guava Preconditions (#3586)#4353
Gteeri wants to merge 2 commits into
Slimefun:experimentalfrom
Gteeri:fix/replace-validate-with-preconditions

Conversation

@Gteeri
Copy link
Copy Markdown

@Gteeri Gteeri commented May 14, 2026

Migrated all usages of org.apache.commons.lang.Validate to com.google.common.base.Preconditions as discussed in issue #3586. This removes the dependency on commons-lang for validation checks.

Description

Proposed changes

Related Issues (if applicable)

Checklist

  • I have fully tested the proposed changes and promise that they will not break everything into chaos.
  • I have also tested the proposed changes in combination with various popular addons and can confirm my changes do not break them.
  • I have made sure that the proposed changes do not break compatibility across the supported Minecraft versions (1.16.* - 1.20.*).
  • I followed the existing code standards and didn't mess up the formatting.
  • I did my best to add documentation to any public classes or methods I added.
  • I have added Nonnull and Nullable annotations to my methods to indicate their behaviour for null values
  • I added sufficient Unit Tests to cover my code.

…mefun#3586)

Migrated all usages of org.apache.commons.lang.Validate to com.google.common.base.Preconditions as discussed in issue Slimefun#3586. This removes the dependency on commons-lang for validation checks.
@Gteeri Gteeri requested a review from a team as a code owner May 14, 2026 11:24
@github-actions github-actions Bot added the ✨ Fix This Pull Request fixes an issue. label May 14, 2026
@github-actions
Copy link
Copy Markdown
Contributor

Your Pull Request was automatically labelled as: "✨ Fix"
Thank you for contributing to this project! ❤️

Fixed incorrect Validate.notEmpty replacements that would not compile. Replaced Validate.noNullElements with explicit null-check loops using Preconditions.checkNotNull.
@Boomer-1
Copy link
Copy Markdown

In case you werent aware, Slimefun has been officially abandoned for 7 months. No further updates will be released.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

✨ Fix This Pull Request fixes an issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants