Proper code formatting

This commit is contained in:
Peter Kappelt 2023-01-16 08:38:59 +01:00 committed by Trenton H
parent 5004771d79
commit 31a03b1d30
2 changed files with 4 additions and 3 deletions

View File

@ -137,7 +137,7 @@ def scan_file_for_barcodes(
barcodes_on_page = barcode_reader(pillow_img) barcodes_on_page = barcode_reader(pillow_img)
detected_barcodes.extend( detected_barcodes.extend(
[(page_num, text) for text in barcodes_on_page] [(page_num, text) for text in barcodes_on_page],
) )
return detected_barcodes return detected_barcodes
@ -149,7 +149,7 @@ def scan_file_for_barcodes(
for current_page_number, page in enumerate(pages_from_path): for current_page_number, page in enumerate(pages_from_path):
barcodes_on_page = barcode_reader(page) barcodes_on_page = barcode_reader(page)
detected_barcodes.extend( detected_barcodes.extend(
[(current_page_number, text) for text in barcodes_on_page] [(current_page_number, text) for text in barcodes_on_page],
) )
return detected_barcodes return detected_barcodes

View File

@ -141,7 +141,8 @@ class Consumer(LoggingMixin):
if Document.objects.filter(archive_serial_number=self.override_asn).exists(): if Document.objects.filter(archive_serial_number=self.override_asn).exists():
self.log( self.log(
"warning", "warning",
f"A document with ASN {self.override_asn} already exists. No ASN will be set!", f"A document with ASN {self.override_asn} already exists. "
+ "No ASN will be set!",
) )
self.override_asn = None self.override_asn = None