Merge pull request #102 from OpenSprinkler/reduce-geocoding-usage

Log invalid locations
This commit is contained in:
Samer Albahra
2020-07-10 05:59:17 -07:00
committed by GitHub

View File

@@ -27,6 +27,7 @@ export default class GoogleMaps extends Geocoder {
} }
if ( !data.results.length ) { if ( !data.results.length ) {
console.log( `No results found for location "${ location }"` );
throw new CodedError( ErrorCode.NoLocationFound ); throw new CodedError( ErrorCode.NoLocationFound );
} }