mirror of
https://github.com/nextcloud/server.git
synced 2026-04-28 17:48:40 -04:00
Merge pull request #3885 from nextcloud/downstream-26529
Skip FailedStorage in background scan
This commit is contained in:
commit
e548d27d3a
1 changed files with 12 additions and 0 deletions
|
|
@ -123,6 +123,12 @@ class Scanner extends PublicEmitter {
|
|||
if (is_null($storage)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// don't bother scanning failed storages (shortcut for same result)
|
||||
if ($storage->instanceOfStorage('OC\Files\Storage\FailedStorage')) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// don't scan the root storage
|
||||
if ($storage->instanceOfStorage('\OC\Files\Storage\Local') && $mount->getMountPoint() === '/') {
|
||||
continue;
|
||||
|
|
@ -166,6 +172,12 @@ class Scanner extends PublicEmitter {
|
|||
if (is_null($storage)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// don't bother scanning failed storages (shortcut for same result)
|
||||
if ($storage->instanceOfStorage('OC\Files\Storage\FailedStorage')) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// if the home storage isn't writable then the scanner is run as the wrong user
|
||||
if ($storage->instanceOfStorage('\OC\Files\Storage\Home') and
|
||||
(!$storage->isCreatable('') or !$storage->isCreatable('files'))
|
||||
|
|
|
|||
Loading…
Reference in a new issue