Skip to content

Fix type and equality issues in problem classes - #154

Merged
pavog merged 4 commits into
masterfrom
fix-critical-bugs
Nov 10, 2026
Merged

pavog merged 4 commits into
masterfrom
fix-critical-bugs

Conversation

@pavog

@pavog pavog commented Nov 10, 2026

Copy link
Copy Markdown
Member

A set of small, independent fixes for type and consistency issues in the analysis and detective classes.

Changes

  • UnsupportedClassVersionProblem: Only add the UpdateJavaSolution if a Java version could be determined. Previously null could be passed to the solution's non-nullable constructor, resulting in a TypeError.
  • MinecraftProblem: isEqual() now uses $insight instanceof static instead of comparing get_class() results. This matches how the subclasses that override isEqual() already check the type.
  • Bukkit\PluginDependencyProblem: getDependencyPluginName() now returns string instead of ?string. The backing property is a non-nullable string, and this matches the Pocketmine counterpart.
  • Detective: Use the correct class name casing WaterFallProxyLog::class, matching the class declaration and the import.

Behaviour notes

  • MinecraftProblem::isEqual() is slightly broader than before
  • Narrowing the return type of getDependencyPluginName() is compatible for callers, but a subclass overriding it with ?string would have to be adjusted.

@pavog
pavog merged commit b0bc94c into master Nov 10, 2026
3 checks passed
@pavog
pavog deleted the fix-critical-bugs branch November 10, 2026 17:01
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