Skip to content

Commit

Permalink
Fix 'Do not use to determine if a sequence is empty' issue in functio…
Browse files Browse the repository at this point in the history
…ns\reconhecimento_de_entidades.py on line 16 #8
  • Loading branch information
mateusfg7 committed Dec 28, 2019
1 parent 28e7b9d commit ab00d02
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion functions/reconhecimento_de_entidades.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def reconhecimento_de_entidades(client, arquivo):
numeroDeEntidadesEncontradas = len(resultado['sentences'])
wordlist = resultado['sentences'][numeroDeEntidadesEncontradas - 1]['detectedEntities']

if len(wordlist) == 0:
if not wordlist:
print("Não foram encontradas nenhuma entidade.")
exit()
else:
Expand Down

0 comments on commit ab00d02

Please sign in to comment.