geolocate: ignore errors returned as dictionaries (#42271)

This commit is contained in:
Frédéric Péters 2020-04-29 12:23:53 +02:00
parent d535eb33ba
commit 0455e3ebf6
1 changed files with 1 additions and 1 deletions

View File

@ -136,7 +136,7 @@ class GeolocateWorkflowStatusItem(WorkflowStatusItem):
except ValueError:
get_logger().error('non-JSON response from geocoding service')
return
if len(data) == 0:
if len(data) == 0 or isinstance(data, dict):
get_logger().info('error finding location')
return
coords = data[0]