remove unnecessary array

This commit is contained in:
Christopher Teutsch 2019-05-08 11:15:55 +02:00
parent 81c0e5cf8f
commit 6202381e52
Signed by: iwonder
GPG Key ID: 0EE33D788D50130D

View File

@ -101,11 +101,8 @@ def get_results_from_pdf(buf: BinaryIO or str, currency: str = None) -> Currency
print('Parsing data... ', end='')
reader = PyPDF3.PdfFileReader(buf)
text = str()
pages = []
for num in range(0, reader.getNumPages()-1):
pages.append(reader.getPage(num))
for page in pages:
text += page.extractText()
text += reader.getPage(num).extractText()
print('Done.')
return get_results_from_text(text, currency=currency)
def get_fileio(date: DTDate, card_type: List[str] = CARD_VISA) -> BinaryIO: # pylint: disable=dangerous-default-value