Catch exception when trying to connect to update server
This commit is contained in:
parent
eda3680997
commit
cb06f3dcb6
@ -39,6 +39,8 @@ class CheckUpdate
|
||||
|
||||
$client = new Client;
|
||||
|
||||
try {
|
||||
|
||||
$response = $client->request('POST',sprintf('%s/%s',self::UPDATE_SERVER,strtolower(config('app.version'))));
|
||||
|
||||
if ($response->getStatusCode() === 200) {
|
||||
@ -49,6 +51,10 @@ class CheckUpdate
|
||||
return $result;
|
||||
}
|
||||
|
||||
} catch (\Exception $e) {
|
||||
Log::debug(sprintf('CU_:- Exception connecting to update server'),['e'=>get_class($e)]);
|
||||
}
|
||||
|
||||
return NULL;
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user