mirror of
https://github.com/nextcloud/server.git
synced 2026-06-13 18:50:47 -04:00
fix(appstore): Also catch ClientException and ServerException
Signed-off-by: Marcel Müller <marcel-mueller@gmx.de>
This commit is contained in:
parent
734dea31a7
commit
779b5da2d3
1 changed files with 3 additions and 1 deletions
|
|
@ -30,7 +30,9 @@
|
|||
*/
|
||||
namespace OC\App\AppStore\Fetcher;
|
||||
|
||||
use GuzzleHttp\Exception\ClientException;
|
||||
use GuzzleHttp\Exception\ConnectException;
|
||||
use GuzzleHttp\Exception\ServerException;
|
||||
use OC\Files\AppData\Factory;
|
||||
use OCP\AppFramework\Http;
|
||||
use OCP\AppFramework\Utility\ITimeFactory;
|
||||
|
|
@ -110,7 +112,7 @@ abstract class Fetcher {
|
|||
$client = $this->clientService->newClient();
|
||||
try {
|
||||
$response = $client->get($this->getEndpoint(), $options);
|
||||
} catch (ConnectException $e) {
|
||||
} catch (ConnectException|ClientException|ServerException $e) {
|
||||
$this->config->setAppValue('settings', 'appstore-fetcher-lastFailure', (string)time());
|
||||
throw $e;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue