Skip to content

Commit

Permalink
initial commit (#16366)
Browse files Browse the repository at this point in the history
  • Loading branch information
pkdotson authored Aug 20, 2021
1 parent a9f502b commit 3faf653
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,9 @@ class CollectionControl extends React.Component {
}

onChange(i, value) {
Object.assign(this.props.value[i], value);
this.props.onChange(this.props.value);
const newValue = [...this.props.value];
newValue[i] = { ...this.props.value[i], ...value };
this.props.onChange(newValue);
}

onAdd() {
Expand Down

0 comments on commit 3faf653

Please sign in to comment.