Skip to content

Commit

Permalink
Remove useless str conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
remi-braun committed Nov 4, 2024
1 parent bb5fce5 commit 3a2d3ff
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions eoreader/products/optical/optical_product.py
Original file line number Diff line number Diff line change
Expand Up @@ -665,10 +665,9 @@ def _get_clean_band_path(
win_suffix = ""
if window is not None:
if path.is_path(window):
win_suffix = f"{path.get_filename(window)}"
win_suffix = path.get_filename(window)
elif isinstance(window, gpd.GeoDataFrame):
win_suffix = f"{window.attrs.get('name')}"

win_suffix = window.attrs.get("name")
if not win_suffix:
win_suffix = f"win{files.hash_file_content(str(window))}"

Expand Down

0 comments on commit 3a2d3ff

Please sign in to comment.