fix(#1270): ensure explorer exists at startup before propagating FS changes
This commit is contained in:
parent
187388b7f5
commit
55aa0062b9
@ -117,6 +117,12 @@ end
|
||||
-- (grouped or hidden too)
|
||||
function M.get_node_from_path(path)
|
||||
local explorer = require("nvim-tree.core").get_explorer()
|
||||
|
||||
-- tree may not yet be loaded
|
||||
if not explorer then
|
||||
return
|
||||
end
|
||||
|
||||
if explorer.absolute_path == path then
|
||||
return explorer
|
||||
end
|
||||
|
||||
Loading…
Reference in New Issue
Block a user