Fix weather restrictions check

This was accidentally removed in a bad merge
This commit is contained in:
Matthew Oslan
2019-05-27 02:56:57 -04:00
parent 7163eae0b2
commit 74f6a00f7b

View File

@@ -253,7 +253,7 @@ export const getWateringData = async function( req: express.Request, res: expres
// Continue with the weather request
let timeData: TimeData = getTimeData( coordinates );
let wateringData: WateringData;
if ( adjustmentMethod !== ADJUSTMENT_METHOD.MANUAL ) {
if ( adjustmentMethod !== ADJUSTMENT_METHOD.MANUAL || checkRestrictions ) {
if ( !weatherProvider.getWateringData ) {
res.send( "Error: selected WeatherProvider does not support getWateringData" );
return;