Skip to content

Commit

Permalink
fix: sort with casefold, case insensitive
Browse files Browse the repository at this point in the history
  • Loading branch information
mashb1t committed Feb 12, 2024
1 parent f4a8bf2 commit a78f66f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ def get_files_from_folder(folder_path, exensions=None, name_filter=None):
relative_path = os.path.relpath(root, folder_path)
if relative_path == ".":
relative_path = ""
for filename in sorted(files):
for filename in sorted(files, key=lambda s: s.casefold()):
_, file_extension = os.path.splitext(filename)
if (exensions == None or file_extension.lower() in exensions) and (name_filter == None or name_filter in _):
path = os.path.join(relative_path, filename)
Expand Down

0 comments on commit a78f66f

Please sign in to comment.