mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-28 11:39:21 +03:00
Replace all new Intl.Collator with new baseCollator
This commit is contained in:
parent
70b1a93108
commit
7450afeecf
7 changed files with 17 additions and 9 deletions
|
|
@ -1,3 +1,4 @@
|
|||
import { baseCollator } from 'Common/Translator';
|
||||
import { AbstractCollectionModel } from 'Model/AbstractCollection';
|
||||
import { AttachmentModel } from 'Model/Attachment';
|
||||
|
||||
|
|
@ -11,7 +12,7 @@ export class AttachmentCollectionModel extends AbstractCollectionModel
|
|||
*/
|
||||
static reviveFromJson(items) {
|
||||
const attachments = super.reviveFromJson(items, attachment => AttachmentModel.reviveFromJson(attachment));
|
||||
let collator = new Intl.Collator(undefined, {numeric: true, sensitivity: 'base'});
|
||||
let collator = baseCollator(true);
|
||||
attachments.sort((a, b) => {
|
||||
if (a.isInline()) {
|
||||
if (!b.isInline()) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue