Skip to content

Commit 0708a1c

Browse files
committed
chore: use entry point open instead of lib open
cannot yet use entry point open in lib.init
1 parent 36afa32 commit 0708a1c

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

lua/nvim-tree.lua

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,7 @@ local _config = {}
1313
local M = {}
1414

1515
function M.focus()
16-
if not view.win_open() then
17-
lib.open()
18-
end
16+
M.open()
1917
view.focus();
2018
end
2119

@@ -29,17 +27,13 @@ function M.toggle(find_file)
2927
if _config.update_focused_file.enable or find_file then
3028
M.find_file(true)
3129
end
32-
if not view.win_open() then
33-
lib.open()
34-
end
30+
M.open()
3531
end
3632
end
3733

3834
function M.open()
3935
if not view.win_open() then
4036
lib.open()
41-
else
42-
lib.set_target_win()
4337
end
4438
end
4539

0 commit comments

Comments
 (0)