Skip to content

Commit

Permalink
typo fix
Browse files Browse the repository at this point in the history
  • Loading branch information
mrmatthewnguyen105 committed Dec 21, 2023
1 parent 3c21480 commit a424f31
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
4 changes: 1 addition & 3 deletions src/_node/file/apis.ts
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,7 @@ export const loadIDBProject = async (
// sort by ASC directory/file
sortFilesByASC(handlerObj);
// define the initialFileUidToOpen
let _initialFileUidToOpen: TNodeUid = isReload
? ""
: getInitialFileUidToOpen(handlerObj);
let _initialFileUidToOpen = getInitialFileUidToOpen(handlerObj);

// build fileTree
const _fileTree: TFileNodeTreeData = {};
Expand Down
1 change: 0 additions & 1 deletion src/pages/main/hooks/useHandlers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,6 @@ export const useHandlers = ({
} = await loadIDBProject(DefaultProjectPath, true, fileTree);
dispatch(setFileTree(_fileTree));
// need to open another file if the current open file is deleted
// dispatch(setCurrentFileUid(_initialFileUidToOpen));
if (deletedUidsObj[currentFileUid]) {
dispatch(setCurrentFileUid(_initialFileUidToOpen));
dispatch(
Expand Down

0 comments on commit a424f31

Please sign in to comment.