We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d663059 commit 3595418Copy full SHA for 3595418
lua/nvim-tree/api.lua
@@ -140,8 +140,11 @@ end)
140
Api.tree.change_root_to_node = wrap_node(function(node)
141
if node.name == ".." or node:is(RootNode) then
142
actions.root.change_dir.fn("..")
143
- elseif node:is(DirectoryNode) then
144
- actions.root.change_dir.fn(node:last_group_node().absolute_path)
+ else
+ node = node:as(DirectoryNode)
145
+ if node then
146
+ actions.root.change_dir.fn(node:last_group_node().absolute_path)
147
+ end
148
end
149
end)
150
lua/nvim-tree/explorer/init.lua
@@ -98,7 +98,7 @@ function Explorer:create_autocmds()
98
callback = function()
99
appearance.setup()
100
view.reset_winhl()
101
- self:draw()
+ self.renderer:draw()
102
end,
103
})
104
0 commit comments