[MERGE] forward port branch saas-15 up to 180f105508
This commit is contained in:
@@ -30,7 +30,13 @@ def geo_find(addr, apikey=False):
|
||||
if result['status'] != 'OK':
|
||||
if result.get('error_message'):
|
||||
_logger.error(result['error_message'])
|
||||
return None
|
||||
error_msg = _('Unable to geolocate, received the error:\n%s'
|
||||
'\n\nGoogle made this a paid feature.\n'
|
||||
'You should first enable billing on your Google account.\n'
|
||||
'Then, go to Developer Console, and enable the APIs:\n'
|
||||
'Geocoding, Maps Static, Maps Javascript.\n'
|
||||
% result['error_message'])
|
||||
raise UserError(error_msg)
|
||||
|
||||
try:
|
||||
geo = result['results'][0]['geometry']['location']
|
||||
|
||||
Reference in New Issue
Block a user