Skip to content

Remove unused CorePlugin methods getCore & getServerType#68

Merged
EarthCow merged 4 commits into
devfrom
improvement/core-plugin-remove-usused-methods
May 30, 2026
Merged

Remove unused CorePlugin methods getCore & getServerType#68
EarthCow merged 4 commits into
devfrom
improvement/core-plugin-remove-usused-methods

Conversation

@EarthCow
Copy link
Copy Markdown
Contributor

Also remove ServerType enum altogether as it is unused as well.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 30, 2026

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 98fa4d25-3ba6-4dd2-9d70-35d8cffa2745

📥 Commits

Reviewing files that changed from the base of the PR and between dfb2511 and 8ab4be6.

📒 Files selected for processing (4)
  • src/main/java/xyz/earthcow/networkjoinmessages/bungee/BungeeMain.java
  • src/main/java/xyz/earthcow/networkjoinmessages/common/abstraction/CorePlugin.java
  • src/main/java/xyz/earthcow/networkjoinmessages/common/abstraction/ServerType.java
  • src/main/java/xyz/earthcow/networkjoinmessages/velocity/VelocityMain.java
💤 Files with no reviewable changes (4)
  • src/main/java/xyz/earthcow/networkjoinmessages/common/abstraction/ServerType.java
  • src/main/java/xyz/earthcow/networkjoinmessages/bungee/BungeeMain.java
  • src/main/java/xyz/earthcow/networkjoinmessages/velocity/VelocityMain.java
  • src/main/java/xyz/earthcow/networkjoinmessages/common/abstraction/CorePlugin.java

📝 Walkthrough

Development

  • Removed unused getCore() method from the CorePlugin interface and its implementations in BungeeMain and VelocityMain
  • Removed unused getServerType() method from the CorePlugin interface and its implementations in BungeeMain and VelocityMain
  • Removed the unused ServerType enum and its BUNGEE and VELOCITY constants

Walkthrough

The pull request removes the ServerType enum and the getCore() and getServerType() methods from the plugin framework. The CorePlugin interface contract is simplified by dropping these declarations, with corresponding import cleanup. Both BungeeMain and VelocityMain implementations no longer override these methods.

Changes

ServerType and Core Method Removal

Layer / File(s) Summary
Remove getCore() and getServerType() from plugin interface and implementations
src/main/java/xyz/earthcow/networkjoinmessages/common/abstraction/CorePlugin.java, src/main/java/xyz/earthcow/networkjoinmessages/bungee/BungeeMain.java, src/main/java/xyz/earthcow/networkjoinmessages/velocity/VelocityMain.java
The CorePlugin interface removes getCore() and getServerType() declarations and drops the Core import. BungeeMain and VelocityMain remove their corresponding method overrides.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🗑️ Out with the old ServerType, away with the getter methods—
A cleaner interface emerges, no more platform exposition,
Bungee and Velocity align with grace,
Leaving the core details out of the public embrace. 🚀

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main change: removing two unused methods (getCore and getServerType) from the CorePlugin interface, which aligns perfectly with the changeset.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch improvement/core-plugin-remove-usused-methods

Comment @coderabbitai help to get the list of available commands and usage tips.

@EarthCow EarthCow changed the base branch from master to dev May 30, 2026 21:37
@EarthCow EarthCow merged commit 0aa5d3e into dev May 30, 2026
2 checks passed
@EarthCow EarthCow deleted the improvement/core-plugin-remove-usused-methods branch May 30, 2026 21:44
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