error checking for geolocation