1
0
mirror of synced 2026-05-22 14:43:19 +00:00

Optimize efficiency ordering tags

This commit is contained in:
Borewit
2025-06-29 10:31:26 +02:00
committed by Borewit
parent 9f6743d107
commit 754a393fbf
2 changed files with 3 additions and 5 deletions
+2 -1
View File
@@ -43,7 +43,8 @@
"suspicious": {
"noEmptyBlockStatements": "error",
"noControlCharactersInRegex": "off",
"useErrorMessage": "error"
"useErrorMessage": "error",
"noAssignInExpressions": "off"
},
"nursery": {}
}
+1 -4
View File
@@ -84,10 +84,7 @@ export function orderTags(nativeTags: ITag[]): INativeTagDict {
const tags: INativeTagDict = {};
for (const { id, value } of nativeTags) {
if (!tags[id]) {
tags[id] = [];
}
tags[id].push(value);
(tags[id] ||= []).push(value);
}
return tags;