Completed geocoding function