case insensitive name sorting

This commit is contained in:
Lilian Jónsdóttir 2024-07-16 11:11:12 -07:00
parent 8a4b195a72
commit 2515756d1d

View file

@ -49,7 +49,9 @@ func SortBySizeReverse(a, b File) int {
}
func SortByName(a, b File) int {
return cmp.Compare(a.Name(), b.Name())
an := strings.ToLower(a.Name())
bn := strings.ToLower(b.Name())
return cmp.Compare(an, bn)
}
func SortByNameReverse(a, b File) int {