[Bug]: Display to "999+" when users limit is reached in Accounts
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 36.9k
- Forks
- 5.2k
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 713
Description
⚠️ This issue respects the following points: ⚠️
- This is a bug, not a question or a configuration/webserver/proxy issue.
- This issue is not already reported on Github OR Nextcloud Community Forum (I've searched it).
- Nextcloud Server is up to date. See Maintenance and Release Schedule for supported versions.
- I agree to follow Nextcloud's Code of Conduct.
Bug description
- Hardcoded limit COUNT_LIMIT_FOR_SUBADMINS = 999 in /apps/settings/lib/Controller/UsersController.php:60
- When user is Group Admin (subadmin), the system intentionally stops counting at 999 users for performance reasons
- UsersController.php:165 calls countUsersAndDisabledUsersOfGroups() with this 999 limit
Steps to reproduce
- Create a Nextcloud user with "Group Admin" privileges for a group containing > 999 users (e.g. 5000 or more).
- Log in as the Group Admin.
- Go to "Accounts"
Expected behavior
Expected behavior
The number of users at "All accounts" shown in the left-hand sidebar should reflect the actual number of users the Group Admin can browse (e.g. "5241").
Actual behavior
The sidebar always shows "All accounts 999", even though the Group Admin can browse through more than 999 users without any issue.
Nextcloud Server version
31
Operating system
None
PHP engine version
None
Web server
None
Database engine version
None
Is this bug present after an update or on a fresh install?
None
Are you using the Nextcloud Server Encryption module?
None
What user-backends are you using?
- Default user-backend (database)
- LDAP/ Active Directory
- SSO - SAML
- Other
Configuration report
List of activated Apps
Nextcloud Signing status
Nextcloud Logs
Additional info
Proposed fix:
- display to "999+" when limit is reached (minimal code change)
- make limit configurable via system config (might affect perfs if big)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in apps/settings/lib/Controller/UsersController.php, especially the COUNT_LIMIT_FOR_SUBADMINS definition at line 60 and the countUsersAndDisabledUsersOfGroups() call around line 165. Reproduce the Group Admin Accounts view with more than 999 users, then verify that the sidebar communicates the capped count appropriately while preserving the existing performance limit.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100