Skip to content

Commit

Permalink
Revert "Remove unused 'main_path' property"
Browse files Browse the repository at this point in the history
This reverts commit 6201c62
  • Loading branch information
urubens committed Jan 6, 2022
1 parent 33aa186 commit 9e92043
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions pims/formats/utils/abstract.py
Original file line number Diff line number Diff line change
Expand Up @@ -297,3 +297,7 @@ def annotations(self) -> List[ParsedMetadataAnnotation]:
@cached_property
def histogram(self):
return self.histogram_reader

@cached_property
def main_path(self):
return self.path
2 changes: 1 addition & 1 deletion pims/importer/listeners.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ def end_unpacking(
uf.contentType = format.get_identifier() # TODO
uf.size = unpacked_path.size
uf.filename = str(unpacked_path.relative_to(FILE_ROOT_PATH))
uf.originalFilename = str(format.path.name)
uf.originalFilename = str(format.main_path.name)
uf.ext = ""
uf.storage = parent.storage
uf.user = parent.user
Expand Down

0 comments on commit 9e92043

Please sign in to comment.