Skip to content

Commit

Permalink
fix(antd/next): fix array-collapse onAdd function nullable issue (#3795)
Browse files Browse the repository at this point in the history
  • Loading branch information
McDaddy committed Apr 19, 2023
1 parent cce787c commit 39fac2b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/antd/src/array-collapse/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ export const ArrayCollapse: ComposedArrayCollapse = observer((props) => {
return (
<ArrayBase
onAdd={(index) => {
onAdd(index)
onAdd?.(index)
setActiveKeys(insertActiveKeys(activeKeys, index))
}}
onCopy={onCopy}
Expand Down
2 changes: 1 addition & 1 deletion packages/next/src/array-collapse/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ export const ArrayCollapse: ComposedArrayCollapse = observer(
return (
<ArrayBase
onAdd={(index) => {
onAdd(index)
onAdd?.(index)
setExpandKeys(insertExpandedKeys(expandKeys, index))
}}
onCopy={onCopy}
Expand Down

0 comments on commit 39fac2b

Please sign in to comment.