Minor improvement

pull/2007/head
David Peer 2022-06-29 19:43:15 +02:00
parent 4a6bfad90d
commit d169dd94ec
1 changed files with 1 additions and 2 deletions

View File

@ -287,8 +287,7 @@ function getWeather(){
// Wind // Wind
const wind = locale.speed(weather.wind).match(/^(\D*\d*)(.*)$/); const wind = locale.speed(weather.wind).match(/^(\D*\d*)(.*)$/);
var speedFactor = settings.speed == "kph" ? 1.0 : 1.0 / 1.60934; weather.wind = Math.round(wind[1]) + "kph";
weather.wind = Math.round(wind[1] * speedFactor);
return weather return weather