diff --git a/src/pdf2aas/preprocessor/pdf/pdf2html_ex.py b/src/pdf2aas/preprocessor/pdf/pdf2html_ex.py index 98085db..794a277 100644 --- a/src/pdf2aas/preprocessor/pdf/pdf2html_ex.py +++ b/src/pdf2aas/preprocessor/pdf/pdf2html_ex.py @@ -160,6 +160,7 @@ def reduce_datasheet( # noqa: C901 if reduced_datasheet_match is None: return "" reduced_datasheet = reduced_datasheet_match.group(1) + reduced_datasheet_list = [] if level >= ReductionLevel.PAGES: logger.debug("Reducing datasheet to ReductionLevel.PAGES") reduced_datasheet_list = re.findall(r'
|
", "", page) + result = reduced_datasheet_list if level >= ReductionLevel.DIVS else reduced_datasheet logger.info("Reduced datasheet to ReductionLevel %s", level.name) - logger.debug("reduced datasheet:\n%s", str(reduced_datasheet_list)) - return reduced_datasheet_list + logger.debug("Reduced datasheet text:\n%s", str(result)) + return result def clear_temp_dir(self) -> None: """Clear the temporary directory used for storing intermediate HTML files."""