From 5697dc4fcf77e5318aa003d88e286e4d87e5ce3c Mon Sep 17 00:00:00 2001 From: kiyan Date: Sat, 5 Feb 2022 14:04:58 +0100 Subject: [PATCH] fix: typo in view for focused file fixes #782 --- lua/nvim-tree/view.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lua/nvim-tree/view.lua b/lua/nvim-tree/view.lua index 6cb7aa81..be266f80 100644 --- a/lua/nvim-tree/view.lua +++ b/lua/nvim-tree/view.lua @@ -283,8 +283,8 @@ function M.close() for _, win in pairs(a.nvim_list_wins()) do if tree_win ~= win and a.nvim_win_get_config(win).relative == "" then a.nvim_win_hide(tree_win) - if tree_win == current_win and M.View.last_focus_winnr then - a.nvim_set_current_win(M.View.last_focus_winnr) + if tree_win == current_win and M.View.last_focused_winnr then + a.nvim_set_current_win(M.View.last_focused_winnr) end return end