Merge pull request #20641 from owncloud/files_external_missing_backend

dont die if the external storage backend doesn't exist
This commit is contained in:
Thomas Müller 2015-11-20 16:06:25 +01:00
commit f3ff858323
1 changed files with 19 additions and 10 deletions

View File

@ -221,17 +221,26 @@ abstract class StoragesService {
$currentStorage->setMountPoint($relativeMountPath);
}
$this->populateStorageConfigWithLegacyOptions(
$currentStorage,
$mountType,
$applicable,
$storageOptions
);
try {
$this->populateStorageConfigWithLegacyOptions(
$currentStorage,
$mountType,
$applicable,
$storageOptions
);
if ($hasId) {
$storages[$configId] = $currentStorage;
} else {
$storagesWithConfigHash[$configId] = $currentStorage;
if ($hasId) {
$storages[$configId] = $currentStorage;
} else {
$storagesWithConfigHash[$configId] = $currentStorage;
}
} catch (\UnexpectedValueException $e) {
// dont die if a storage backend doesn't exist
\OCP\Util::writeLog(
'files_external',
'Could not load storage: "' . $e->getMessage() . '"',
\OCP\Util::ERROR
);
}
}
}