added check for lat/lon