FIx wind chill in Fahrenheit.

This commit is contained in:
Michael Teeuw 2018-04-02 12:58:19 +02:00
parent 4daf2e4a3d
commit 10eb41d319
2 changed files with 3 additions and 2 deletions

View File

@ -11,6 +11,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
### Changed
### Fixed
- Fixed issue where wind chill could not be displayed in Fahrenheit. [#1247](https://github.com/MichMich/MagicMirror/issues/1247)
### Updated
- Updated italian translation

View File

@ -407,8 +407,8 @@ Module.register("currentweather",{
if (windInMph > 3 && tempInF < 50){
// windchill
var windchillinF = Math.round(35.74+0.6215*tempInF-35.75*Math.pow(windInMph,0.16)+0.4275*tempInF*Math.pow(windInMph,0.16));
var windChillInC = (windchillinF - 32) * (5/9);
var windChillInF = Math.round(35.74+0.6215*tempInF-35.75*Math.pow(windInMph,0.16)+0.4275*tempInF*Math.pow(windInMph,0.16));
var windChillInC = (windChillInF - 32) * (5/9);
// this.feelsLike = windChillInC.toFixed(0);
switch (this.config.units){