diff options
author | Christian Paier <hallo+git@cpaier.com> | 2022-02-05 23:26:55 +0100 |
---|---|---|
committer | Christian Paier <hallo+git@cpaier.com> | 2022-02-05 23:54:56 +0100 |
commit | 9476ce70ed326304afeb9b5aab3a412b4f1acaaa (patch) | |
tree | 5766ef2656f796f62722fa03667d024882f5b1a0 /lib | |
parent | 9c2db7f4e40d690890024636856ec51fbcb00005 (diff) | |
download | nextcloud-server-9476ce70ed326304afeb9b5aab3a412b4f1acaaa.tar.gz nextcloud-server-9476ce70ed326304afeb9b5aab3a412b4f1acaaa.zip |
Removes misleading error message in occ files:scan for new users.
Previously the occ files:scan command printed an error message for any
new users without any files/folders in the data directory.
With this change only users with any file/folder is scanned.
This fixes #25433.
Signed-off-by: Christian Paier <hallo+git@cpaier.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Files/Utils/Scanner.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Files/Utils/Scanner.php b/lib/private/Files/Utils/Scanner.php index 2e5a25a355b..5b633617608 100644 --- a/lib/private/Files/Utils/Scanner.php +++ b/lib/private/Files/Utils/Scanner.php @@ -216,7 +216,7 @@ class Scanner extends PublicEmitter { if ($storage->instanceOfStorage('\OC\Files\Storage\Home') and (!$storage->isCreatable('') or !$storage->isCreatable('files')) ) { - if ($storage->file_exists('') or $storage->getCache()->inCache('')) { + if ($storage->is_dir('files')) { throw new ForbiddenException(); } else {// if the root exists in neither the cache nor the storage the user isn't setup yet break; |