feat: try sort as ignore-case

https://github.com/AUTOMATIC1111/stable-diffusion-webui/issues/8368
This commit is contained in:
bluelovers
2023-03-12 10:18:33 +08:00
parent 0cc0ee1bcb
commit 0492424121
3 changed files with 4 additions and 4 deletions

View File

@@ -702,7 +702,7 @@ mem_mon.start()
def listfiles(dirname):
filenames = [os.path.join(dirname, x) for x in sorted(os.listdir(dirname)) if not x.startswith(".")]
filenames = [os.path.join(dirname, x) for x in sorted(os.listdir(dirname), key=str.lower) if not x.startswith(".")]
return [file for file in filenames if os.path.isfile(file)]