Skip to content

Commit

Permalink
fix(weatherstatus): make a difference between 'unknown weather code' …
Browse files Browse the repository at this point in the history
…and 'no weather info'

Signed-off-by: Julien Veyssier <[email protected]>
  • Loading branch information
julien-nc committed Sep 25, 2024
1 parent 9b67e43 commit d730082
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions apps/weather_status/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -293,15 +293,19 @@ export default {
return t('weather_status', 'Loading weather')
} else if (this.errorMessage) {
return this.errorMessage
} else {
} else if (this.gotWeather) {
return this.getWeatherMessage(this.weatherCode, this.temperature)
} else {
return t('weather_status', 'Set location for weather')
}
},
forecastMessage() {
if (this.loading) {
return t('weather_status', 'Loading weather')
} else {
} else if (this.gotWeather) {
return this.getWeatherMessage(this.futureWeatherCode, this.futureTemperature, true)
} else {
return t('weather_status', 'Set location for weather')
}
},
weatherLinkTarget() {
Expand Down Expand Up @@ -535,7 +539,7 @@ export default {
this.temperatureUnit,
later,
)
: t('weather_status', 'Set location for weather')
: t('weather_status', 'Unknown weather code')
},
},
}
Expand Down

0 comments on commit d730082

Please sign in to comment.