mirror of
https://github.com/SukkaW/Surge.git
synced 2026-02-03 20:41:52 +08:00
Perf: further speed up infra
This commit is contained in:
@@ -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}`)
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user