Change reply to 100% when invalid data is recieved
This commit is contained in:
@@ -194,7 +194,7 @@ function calculateWeatherScale( adjustmentMethod, adjustmentOptions, weather ) {
|
|||||||
|
|
||||||
// Check to make sure valid data exists for all factors
|
// Check to make sure valid data exists for all factors
|
||||||
if ( !validateValues( [ "temp", "humidity", "precip" ], weather ) ) {
|
if ( !validateValues( [ "temp", "humidity", "precip" ], weather ) ) {
|
||||||
return -1;
|
return 100;
|
||||||
}
|
}
|
||||||
|
|
||||||
var temp = ( ( weather.maxTemp + weather.minTemp ) / 2 ) || weather.temp,
|
var temp = ( ( weather.maxTemp + weather.minTemp ) / 2 ) || weather.temp,
|
||||||
|
|||||||
Reference in New Issue
Block a user