only use mount provider if we have a valid user
This commit is contained in:
parent
24131586d7
commit
6f47a547d8
1 changed files with 4 additions and 2 deletions
|
@ -436,8 +436,10 @@ class Filesystem {
|
|||
$mountConfigManager->listen('\OC\Files\Config', 'registerMountProvider', function (IMountProvider $provider) use ($userManager) {
|
||||
foreach (Filesystem::$usersSetup as $user => $setup) {
|
||||
$userObject = $userManager->get($user);
|
||||
$mounts = $provider->getMountsForUser($userObject, Filesystem::getLoader());
|
||||
array_walk($mounts, array(self::$mounts, 'addMount'));
|
||||
if ($userObject) {
|
||||
$mounts = $provider->getMountsForUser($userObject, Filesystem::getLoader());
|
||||
array_walk($mounts, array(self::$mounts, 'addMount'));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue