Skip to content

RE1-T115 Bug fix#374

Merged
ucswift merged 1 commit intomasterfrom
develop
May 7, 2026
Merged

RE1-T115 Bug fix#374
ucswift merged 1 commit intomasterfrom
develop

Conversation

@ucswift
Copy link
Copy Markdown
Member

@ucswift ucswift commented May 7, 2026

Summary by CodeRabbit

  • Bug Fixes
    • Improved reliability of the personnel staffing display by implementing proper null handling and fallback logic. The system now gracefully defaults to standard values when custom staffing information is unavailable, preventing potential display errors.

@request-info
Copy link
Copy Markdown

request-info Bot commented May 7, 2026

Thanks for opening this, but we'd appreciate a little more information. Could you update it with more details?

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 7, 2026

Review Change Stack
No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 2150d41e-f3aa-402b-9e59-fc0398149481

📥 Commits

Reviewing files that changed from the base of the PR and between 3518a7c and a74a754.

📒 Files selected for processing (1)
  • Web/Resgrid.Web.Services/Controllers/v4/PersonnelController.cs

📝 Walkthrough

Walkthrough

The PR introduces a null-safety guard in PersonnelController.ConvertPersonnelInfo where staffing values from CustomStatesHelper.GetCustomPersonnelStaffing() are now conditionally assigned. When the helper returns a non-null staffing object, the controller uses its values; otherwise it applies safe defaults.

Changes

Staffing Null-Safety

Layer / File(s) Summary
Staffing Null Guard
Web/Resgrid.Web.Services/Controllers/v4/PersonnelController.cs
Staffing assignment now conditionally uses returned staffing object if non-null, otherwise applies default "Available" and "#000" values.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Title check ❓ Inconclusive The PR title references only a ticket identifier and generic term without describing the actual change; it fails to convey what the bug fix addresses. Provide a more descriptive title that explains the specific bug being fixed, such as 'Fix null dereference risk in personnel staffing display logic'.
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
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 docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch develop

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@ucswift
Copy link
Copy Markdown
Member Author

ucswift commented May 7, 2026

Approve

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is approved.

@ucswift ucswift merged commit 2ed7f3f into master May 7, 2026
19 checks 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.

1 participant