Skip to content

refactor(stat): removed unused function#27

Merged
liang799 merged 1 commit into
mainfrom
tianpok/cleanup
Apr 10, 2026
Merged

refactor(stat): removed unused function#27
liang799 merged 1 commit into
mainfrom
tianpok/cleanup

Conversation

@liang799

@liang799 liang799 commented Apr 10, 2026

Copy link
Copy Markdown
Owner

Summary by CodeRabbit

  • Refactor
    • Simplified internal API by removing a redundant method; underlying functionality remains unchanged.

@coderabbitai

coderabbitai Bot commented Apr 10, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: ae6f7082-2ea9-4fd4-9d7b-b88657fddeab

📥 Commits

Reviewing files that changed from the base of the PR and between 4c26eb3 and 965d13d.

📒 Files selected for processing (1)
  • src/main/java/sc2002/turnbased/domain/Stat.java
💤 Files with no reviewable changes (1)
  • src/main/java/sc2002/turnbased/domain/Stat.java

📝 Walkthrough

Walkthrough

A public adjustBy(int amount) method has been removed from the Stat class. The method was a thin wrapper that delegated directly to addFlat(amount), so callers now have one fewer API option while the underlying implementation remains available.

Changes

Cohort / File(s) Summary
Method Removal
src/main/java/sc2002/turnbased/domain/Stat.java
Removed the public adjustBy(int amount) method, which was a simple delegation wrapper to addFlat(amount). The underlying addFlat(int) method and other functionality remain unchanged.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐰 A method once stood, now fades away,
Redundant whispers had their say,
For addFlat remains, strong and true,
One path instead of two will do! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'refactor(stat): removed unused function' accurately describes the main change—removing the unused adjustBy method from the Stat class.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

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

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch tianpok/cleanup

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

@liang799
liang799 merged commit 6d62f92 into main Apr 10, 2026
3 checks passed
@liang799
liang799 deleted the tianpok/cleanup branch April 10, 2026 05:49
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