Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Paier <hallo+git@cpaier.com>2022-02-06 01:26:55 +0300
committerChristian Paier <hallo+git@cpaier.com>2022-02-06 01:54:56 +0300
commit9476ce70ed326304afeb9b5aab3a412b4f1acaaa (patch)
tree5766ef2656f796f62722fa03667d024882f5b1a0 /lib/private/Files
parent9c2db7f4e40d690890024636856ec51fbcb00005 (diff)
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/private/Files')
-rw-r--r--lib/private/Files/Utils/Scanner.php2
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;