Perf: further speed up infra

This commit is contained in:
SukkaW
2023-09-14 20:15:49 +08:00
parent adb8b43357
commit 78afa595a9
25 changed files with 431 additions and 173 deletions

View File

@@ -19,8 +19,15 @@ runner(__filename, async () => {
results.push(
...Object.entries(DOMESTICS)
.filter(([key]) => key !== 'SYSTEM')
.flatMap(([, { domains }]) => domains)
.reduce(
(acc, [key, { domains }]) => {
if (key === 'SYSTEM') {
return acc;
}
return [...acc, ...domains];
},
/** @type {string[]} */([])
)
.sort(domainSorter)
.map((domain) => `DOMAIN-SUFFIX,${domain}`)
);