forked from Ponysearch/Ponysearch
[fix] use address.city if possible
This commit is contained in:
parent
3b7b106684
commit
bc12a76fbb
1 changed files with 3 additions and 1 deletions
|
@ -64,7 +64,9 @@ def response(resp):
|
||||||
if address.get('name'):
|
if address.get('name'):
|
||||||
address.update({'house_number':address_raw.get('house_number'),
|
address.update({'house_number':address_raw.get('house_number'),
|
||||||
'road':address_raw.get('road'),
|
'road':address_raw.get('road'),
|
||||||
'locality':address_raw.get('town', address_raw.get('village')),
|
'locality':address_raw.get('city',
|
||||||
|
address_raw.get('town',
|
||||||
|
address_raw.get('village'))),
|
||||||
'postcode':address_raw.get('postcode'),
|
'postcode':address_raw.get('postcode'),
|
||||||
'country':address_raw.get('country'),
|
'country':address_raw.get('country'),
|
||||||
'country_code':address_raw.get('country_code')})
|
'country_code':address_raw.get('country_code')})
|
||||||
|
|
Loading…
Reference in a new issue