Skip to content

Commit 2ee6f6a

Browse files
committed
fix(#1731): do not fire folder created event on file create
1 parent 5dfd8bd commit 2ee6f6a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lua/nvim-tree/actions/fs/create-file.lua

+1-1
Original file line numberDiff line numberDiff line change
@@ -99,12 +99,12 @@ function M.fn(node)
9999
is_error = true
100100
break
101101
end
102+
events._dispatch_folder_created(new_file_path)
102103
end
103104
end
104105
if not is_error then
105106
notify.info(new_file_path .. " was properly created")
106107
end
107-
events._dispatch_folder_created(new_file_path)
108108
if M.enable_reload then
109109
require("nvim-tree.actions.reloaders.reloaders").reload_explorer()
110110
else

0 commit comments

Comments
 (0)