Don't take case in count when sorting non-ordered vector flag
Fixes: https://gitlab.cri.epita.fr/ing/majeures/srs/fic/server/-/issues/30
This commit is contained in:
parent
20272e7bad
commit
6fd14306e1
2 changed files with 17 additions and 3 deletions
|
@ -67,7 +67,10 @@ func getRawKey(input interface{}, validatorRe string, ordered bool, showLines bo
|
|||
|
||||
ignord := "f"
|
||||
if !ordered {
|
||||
sort.Strings(fitems)
|
||||
// Sort the list without taking the case in count.
|
||||
sort.Slice(fitems, func(i, j int) bool {
|
||||
return strings.ToLower(fitems[i]) < strings.ToLower(fitems[j])
|
||||
})
|
||||
ignord = "t"
|
||||
}
|
||||
|
||||
|
|
Reference in a new issue