exclude protected users from user count in home api#1576
Merged
nikhilsinhaparseable merged 1 commit intoparseablehq:mainfrom Mar 9, 2026
Merged
Conversation
Contributor
WalkthroughThe PR modifies the user count calculation in Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Suggested labels
Poem
🚥 Pre-merge checks | ✅ 1 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (1 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Contributor
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@src/prism/home/mod.rs`:
- Around line 162-166: The current logic computes user_count as number of
non-protected users but still uses user_added = user_count > 1, which
incorrectly requires two non-protected users; change the threshold to user_added
= user_count > 0 so a single non-protected user marks user_added. Update the
assignment of user_added in src/prism/home/mod.rs (references: users(),
tenant_id, DEFAULT_TENANT, user_count, user_added) and adjust the inline comment
to reflect "at least one non-protected user".
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 6b802298-b868-427a-ab13-07a14e7eaf24
📒 Files selected for processing (1)
src/prism/home/mod.rs
nitisht
approved these changes
Mar 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary by CodeRabbit