Skip to content

Commit

Permalink
fix move dirent to searched folder failed
Browse files Browse the repository at this point in the history
  • Loading branch information
zhouwenxuan authored and zhouwenxuan committed Dec 16, 2024
1 parent 034d756 commit dd329af
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions frontend/src/components/dialog/move-dirent-dialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -237,14 +237,16 @@ class MoveDirent extends React.Component {

onUpdateSearchResults = (results) => {
this.setState({
searchResults: results
searchResults: results,
selectedRepo: results.length > 0 ? new RepoInfo(results[0]) : null,
selectedPath: results.length > 0 ? results[0].path : '',
});
};

onDirentItemClick = (repo, selectedPath) => {
this.setState({
selectedPath: selectedPath,
repo,
selectedRepo: repo,
errMessage: '',
});
};
Expand Down

0 comments on commit dd329af

Please sign in to comment.