mirror of
https://github.com/oven-sh/bun
synced 2026-02-02 15:08:46 +00:00
Simplify getting Set of extentions (#4975)
This commit is contained in:
@@ -15,8 +15,8 @@ for (let key of Object.keys(json).sort()) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const withExtensions = [
|
const withExtensions = [
|
||||||
...new Set([
|
...new Set(
|
||||||
...Object.keys(json)
|
Object.keys(json)
|
||||||
.filter(key => {
|
.filter(key => {
|
||||||
return !!json[key]?.extensions?.length;
|
return !!json[key]?.extensions?.length;
|
||||||
})
|
})
|
||||||
@@ -26,7 +26,7 @@ const withExtensions = [
|
|||||||
});
|
});
|
||||||
})
|
})
|
||||||
.sort(),
|
.sort(),
|
||||||
]),
|
),
|
||||||
];
|
];
|
||||||
|
|
||||||
all += "\n";
|
all += "\n";
|
||||||
|
|||||||
Reference in New Issue
Block a user