Skip to content

Commit a8112d7

Browse files
authored
fix: Duplicate values during deep assign of extra files
Follow up from: #6841 (comment) Filters out duplicate assign's when cascading configs (files, extraFiles, etc.) by converting to Set first
1 parent 62cf003 commit a8112d7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/builder-util/src/deepAssign.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ function assignKey(target: any, from: any, key: string) {
1818
if (prevValue == null || value == null || !isObject(prevValue) || !isObject(value)) {
1919
// Merge arrays.
2020
if (Array.isArray(prevValue) && Array.isArray(value)) {
21-
target[key] = prevValue.concat(value)
21+
target[key] = Array.from(new Set(prevValue.concat(value)))
2222
} else {
2323
target[key] = value
2424
}

0 commit comments

Comments
 (0)