Skip to content

Commit 4cba4e1

Browse files
author
Jan Sebastian Rothe
committed
List with unique names
1 parent eb39086 commit 4cba4e1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/fagfunksjoner/paths/versions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ def get_latest_fileversions(glob_list_path: list[str]) -> list[str]:
9191
latest_files = get_latest_fileversions(all_files)
9292
"""
9393
# Extract unique base names by splitting before the version part
94-
uniques = [file.rsplit("_v", 1)[0] for file in glob_list_path]
94+
uniques = list(dict.fromkeys([file.rsplit("_v", 1)[0] for file in glob_list_path]))
9595
result = []
9696

9797
for unique in uniques:

0 commit comments

Comments
 (0)