Skip to content

Commit f4424fe

Browse files
committed
fix: consider extension when deduping outputs
1 parent 2bfb8c2 commit f4424fe

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/make.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,14 @@ export async function mkdist(
103103
basename(output.path, extname(output.path)) + output.extension;
104104
output.path = join(dirname(output.path), renamed);
105105
// Avoid overriding files with original extension
106-
if (outputs.some((o) => o !== output && o.path === output.path)) {
106+
if (
107+
outputs.some(
108+
(o) =>
109+
o !== output &&
110+
o.path === output.path &&
111+
(!o.extension || o.extension === output.extension),
112+
)
113+
) {
107114
output.skip = true;
108115
}
109116
}

0 commit comments

Comments
 (0)