OCR, Parsing: Revert iterator stop

Revert how the OCR and document parsing generators end
their iteration. Originally they issue an empty return,
then a blank yield was added. This commit reverts the
blank yield and restores the original 'return' behavior.

Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
Roberto Rosario
2018-11-27 17:15:38 -04:00
parent 141d79afa6
commit 67e79d0e19
2 changed files with 2 additions and 2 deletions

View File

@@ -14,7 +14,7 @@ def get_document_content(document):
try:
page_content = page.content.content
except DocumentPageContent.DoesNotExist:
yield ''
return
else:
yield conditional_escape(force_text(page_content))