Merge pull request #13762 from nextcloud/backport/13730/stable15
[stable15] Respect user locale in natural sort comparator
This commit is contained in:
commit
51cd99d089
|
@ -2078,12 +2078,9 @@ OC.Util = {
|
|||
if (aNum == aa[x] && bNum == bb[x]) {
|
||||
return aNum - bNum;
|
||||
} else {
|
||||
// Forcing 'en' locale to match the server-side locale which is
|
||||
// always 'en'.
|
||||
//
|
||||
// Note: This setting isn't supported by all browsers but for the ones
|
||||
// Note: This locale setting isn't supported by all browsers but for the ones
|
||||
// that do there will be more consistency between client-server sorting
|
||||
return aa[x].localeCompare(bb[x], 'en');
|
||||
return aa[x].localeCompare(bb[x], OC.getLanguage());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue