Skip to content

Commit

Permalink
fix: always change treeProps.expandedKeys to avoid wrong loadling data
Browse files Browse the repository at this point in the history
  • Loading branch information
bbb169 committed Oct 13, 2024
1 parent de83565 commit d1181f7
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/OptionList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -211,9 +211,7 @@ const OptionList: React.ForwardRefRenderFunction<ReviseRefOptionListProps> = (_,
if (treeLoadedKeys) {
treeProps.loadedKeys = treeLoadedKeys;
}
if (mergedExpandedKeys) {
treeProps.expandedKeys = mergedExpandedKeys;
}
treeProps.expandedKeys = mergedExpandedKeys || []

Check notice

Code scanning / CodeQL

Semicolon insertion Note

Avoid automated semicolon insertion (95% of all statements in
the enclosing function
have an explicit semicolon).

return (
<div onMouseDown={onListMouseDown}>
Expand Down

0 comments on commit d1181f7

Please sign in to comment.