You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Not specifying a user should request which users to clean, or show help, as with other commands
Actual behaviour
Failing to specify a user cleans all trash for all users, making file recovery impossible
This is easy to accidentally invoke, especially when probing for usage as other commands display, risking data loss
Server configuration
Core component "files" on NC13.0.4
Operating system:
All Web server:
All Database:
All PHP version:
All Nextcloud version: (see Nextcloud admin page)
13.0.4
Comments
The default behaviour (the fall-through) is more dangerous than the specific case. e.g. user:disable without parameters doesn't disable all users, but throws an exception. The trashbin:cleanup command should also fall through safely without parameters.
Replace the default "no uid specified" case with an exception
Only invoke action on all users with trashbin:cleanup --all(-users).
The text was updated successfully, but these errors were encountered:
GitMate.io thinks possibly related issues are #4909 (make changes to users.), #5165 (make logrotation active by default), #9848 (Customize default for the resharing option), #8836 (Where is my trashbin?), and #3173 (corruption cleanup?).
Steps to reproduce
php ./occ trashbin:cleanup <user>
cleans one userphp ./occ trashbin:cleanup
cleans all usersExpected behaviour
Actual behaviour
Server configuration
Core component "files" on NC13.0.4
Operating system:
All
Web server:
All
Database:
All
PHP version:
All
Nextcloud version: (see Nextcloud admin page)
13.0.4
Comments
The default behaviour (the fall-through) is more dangerous than the specific case. e.g.
user:disable
without parameters doesn't disable all users, but throws an exception. Thetrashbin:cleanup
command should also fall through safely without parameters.trashbin:cleanup --all(-users)
.The text was updated successfully, but these errors were encountered: