From 8c77fdef3eac77474ff83a8fc179d38696e19ce0 Mon Sep 17 00:00:00 2001 From: Morris Jobke Date: Mon, 22 Feb 2016 14:30:32 +0100 Subject: [PATCH] Avoids scanning the root storage This check will skip the background scan for the root storage because there is nothing in the root storage that isn't already in another (mostly user-) storage. Fixes #22501 --- lib/private/files/utils/scanner.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/private/files/utils/scanner.php b/lib/private/files/utils/scanner.php index 59673a306cb..bc815f5f6da 100644 --- a/lib/private/files/utils/scanner.php +++ b/lib/private/files/utils/scanner.php @@ -119,6 +119,10 @@ class Scanner extends PublicEmitter { if (is_null($mount->getStorage())) { continue; } + // don't scan the root storage + if ($mount->getStorage()->instanceOfStorage('\OC\Files\Storage\Local') && $mount->getMountPoint() === '/') { + continue; + } $scanner = $mount->getStorage()->getScanner(); $this->attachListener($mount); $scanner->backgroundScan(); -- 2.39.5