Avoid crash when searching for USA

This commit is contained in:
Edward Betts 2021-10-22 10:01:46 +01:00
parent 83a06d9ed7
commit 14abffe79c
1 changed files with 1 additions and 1 deletions

View File

@ -88,7 +88,7 @@ def get_hit_name(hit):
if country_code:
country_code == country_code.lower()
if country_code == "us":
if country_code == "us" and "state" in address:
state = address["state"]
return f"{n1}, {state}, USA"