summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2015-07-13 18:51:25 +0200
committerVincent Petry <pvince81@owncloud.com>2015-07-13 18:51:25 +0200
commit3d6be69f25d1bffc17d252b6e230fecf3618ac9b (patch)
tree32280e2ccd8d43c741b1cdb476f2eaf2d914af45
parente18d0e26f6b5fbef555acacb7d1ec7adbff1c50e (diff)
downloadnextcloud-server-3d6be69f25d1bffc17d252b6e230fecf3618ac9b.tar.gz
nextcloud-server-3d6be69f25d1bffc17d252b6e230fecf3618ac9b.zip
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.
-rw-r--r--apps/files_sharing/lib/external/storage.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files_sharing/lib/external/storage.php b/apps/files_sharing/lib/external/storage.php
index 3284a60172f..dc8d1738b05 100644
--- a/apps/files_sharing/lib/external/storage.php
+++ b/apps/files_sharing/lib/external/storage.php
@@ -253,7 +253,7 @@ class Storage extends DAV implements ISharedStorage {
// 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
// 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);