Skip to content

Commit

Permalink
Fixups
Browse files Browse the repository at this point in the history
  • Loading branch information
tw4l committed Aug 5, 2023
1 parent c581f25 commit 7fda5e5
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions diskimageprocessor.py
Original file line number Diff line number Diff line change
Expand Up @@ -280,11 +280,7 @@ def create_aspace_excel_sheet(args, sips, volumes, logger):
logger.error(f"Error setting permissions: {err}")

workbook = openpyxl.load_workbook(filename=xlsx_path)
worksheet = workbook.get_sheet_by_name("Data")

# TODO: Remove when no longer necessary
if worksheet is None:
logger.error("FOR TESTING: worksheet is none")
worksheet = workbook["Data"]

# TODO: Deduplicate with create_speadsheet
# Maybe create separate method that creates dict with info, and handle
Expand Down Expand Up @@ -424,7 +420,7 @@ def create_aspace_excel_sheet(args, sips, volumes, logger):

logger.info("Described %s successfully." % (sip_path))

workbook.save()
workbook.save(xlsx_path)
workbook.close()

logger.info("ArchivesSpace description XLSX created.")
Expand Down

0 comments on commit 7fda5e5

Please sign in to comment.