More error handling
This commit is contained in:
parent
3b5ddb417c
commit
aebb900cd4
1 changed files with 6 additions and 2 deletions
|
@ -446,8 +446,12 @@ class Google extends \OC\Files\Storage\Common {
|
|||
'save_to' => $tmpFile,
|
||||
]);
|
||||
} catch (RequestException $e) {
|
||||
if ($e->getResponse()->getStatusCode() === 404) {
|
||||
return false;
|
||||
if(!is_null($e->getResponse())) {
|
||||
if ($e->getResponse()->getStatusCode() === 404) {
|
||||
return false;
|
||||
} else {
|
||||
throw $e;
|
||||
}
|
||||
} else {
|
||||
throw $e;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue