Throw storage not available on guzzle error

If the remote server is in maintenance mode, we must throw storage not
available exception instead of not found which might auto-remove the
share.
This commit is contained in:
Vincent Petry 2015-07-13 18:51:25 +02:00
parent e18d0e26f6
commit 3d6be69f25
1 changed files with 1 additions and 1 deletions

View File

@ -253,7 +253,7 @@ class Storage extends DAV implements ISharedStorage {
// throw this to be on the safe side: the share will still be visible // throw this to be on the safe side: the share will still be visible
// in the UI in case the failure is intermittent, and the user will // in the UI in case the failure is intermittent, and the user will
// be able to decide whether to remove it if it's really gone // be able to decide whether to remove it if it's really gone
throw new NotFoundException(); throw new StorageNotAvailableException();
} }
return json_decode($response->getBody(), true); return json_decode($response->getBody(), true);