Fixes in how METARs are parsed

This commit is contained in:
Nabeel Shahzad
2018-04-04 09:04:14 -05:00
parent 7a3a2f3e9a
commit 052813ba4a
4 changed files with 29 additions and 9 deletions

View File

@@ -39,6 +39,9 @@ abstract class Metar
$raw_metar = Cache::remember($key, $cache['time'], function () use ($icao) {
try {
return $this->metar($icao);
} catch (\GuzzleHttp\Exception\GuzzleException $e) {
Log::error('Error getting METAR: '.$e->getMessage(), $e->getTrace());
return '';
} catch (\Exception $e) {
Log::error('Error getting METAR: '. $e->getMessage(), $e->getTrace());
return '';