Add unknown weather data flag
This commit is contained in:
@@ -237,11 +237,14 @@ class Feed extends PhpObject {
|
||||
$sWeatherCond = $asWeather['currentConditions']['conditions'];
|
||||
$sWeatherTemp = $asWeather['currentConditions']['temp'];
|
||||
}
|
||||
else { //Daily Conditions
|
||||
elseif($asWeather['days'][0]['icon'] != '') { //Daily Conditions
|
||||
$sWeatherIcon = $asWeather['days'][0]['icon'];
|
||||
$sWeatherCond = $asWeather['days'][0]['conditions'];
|
||||
$sWeatherTemp = $asWeather['days'][0]['temp'];
|
||||
}
|
||||
else {
|
||||
$sWeatherIcon = 'unknown';
|
||||
}
|
||||
|
||||
//Get Condition ID
|
||||
$sCondKey = (new Translator(self::WEATHER_PARAM['lang']))->getTranslationKey($sWeatherCond);
|
||||
|
||||
Reference in New Issue
Block a user