better error message on catalog error
Signed-off-by: Robin Appelman <robin@icewind.nl>
This commit is contained in:
parent
df6e23c98c
commit
85d23dd6fc
|
@ -84,10 +84,11 @@ class ObjectHomeMountProvider implements IHomeMountProvider {
|
|||
if (!isset($config['arguments'])) {
|
||||
$config['arguments'] = [];
|
||||
}
|
||||
$config['arguments']['user'] = $user;
|
||||
// instantiate object store implementation
|
||||
$config['arguments']['objectstore'] = new $config['class']($config['arguments']);
|
||||
|
||||
$config['arguments']['user'] = $user;
|
||||
|
||||
return $config;
|
||||
}
|
||||
|
||||
|
|
|
@ -117,6 +117,10 @@ class Swift implements IObjectStore {
|
|||
/** @var Catalog $catalog */
|
||||
$catalog = $this->client->getCatalog();
|
||||
|
||||
if (count($catalog->getItems()) === 0) {
|
||||
throw new StorageAuthException('Keystone did not provide a valid catalog, verify the credentials');
|
||||
}
|
||||
|
||||
if (isset($this->params['serviceName'])) {
|
||||
$serviceName = $this->params['serviceName'];
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue