mirror of
https://github.com/nextcloud/server.git
synced 2026-06-09 00:32:29 -04:00
[weather widget] only display integer temperatures
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
This commit is contained in:
parent
63a9bc2aac
commit
e497b30744
3 changed files with 5 additions and 5 deletions
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -462,7 +462,7 @@ export default {
|
|||
},
|
||||
getLocalizedTemperature(celcius) {
|
||||
return this.useFahrenheitLocale
|
||||
? ((celcius * (9 / 5)) + 32).toFixed(1)
|
||||
? (celcius * (9 / 5)) + 32
|
||||
: celcius
|
||||
},
|
||||
onAddRemoveFavoriteClick() {
|
||||
|
|
@ -511,7 +511,7 @@ export default {
|
|||
getWeatherMessage(weatherCode, temperature, later = false) {
|
||||
return weatherCode && weatherCode in weatherOptions
|
||||
? weatherOptions[weatherCode].text(
|
||||
this.getLocalizedTemperature(temperature),
|
||||
Math.round(this.getLocalizedTemperature(temperature)),
|
||||
this.temperatureUnit,
|
||||
later
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue