fix error when no useful label
This commit is contained in:
parent
bb68a46f59
commit
f2a264054c
|
@ -56,5 +56,5 @@ def from_name(name):
|
|||
if 'en' in entity['descriptions']:
|
||||
i['description'] = entity['descriptions']['en']['value']
|
||||
found.append(i)
|
||||
found.sort(key=lambda i: i['label'])
|
||||
found.sort(key=lambda i: i.get('label', ''))
|
||||
return found
|
||||
|
|
Loading…
Reference in a new issue