fix: typo, check direction

This commit is contained in:
əlemi 2024-09-07 04:05:29 +02:00
parent 5c3f7dc85e
commit 9eb057eeac
Signed by: alemi
GPG key ID: A4895B84D311642C
2 changed files with 3 additions and 2 deletions

View file

@ -13,8 +13,9 @@ M.refresh = require("neo-tree.utils").wrap(manager.refresh, "codemp")
M.open = function(state, path, extra) M.open = function(state, path, extra)
local selected = state.tree:get_node() local selected = state.tree:get_node()
if selected.type == "spacer" then return end if selected.type == "spacer" then return end
if selected.type == "title" then return end
if selected.type == "root" then if selected.type == "root" then
if selected.name == "[connect]" and session.client ~= nil then if selected.name == "[connect]" and session.client == nil then
client_manager.connect() client_manager.connect()
end end
return return

View file

@ -49,7 +49,7 @@ end
M.name = function(config, node, state) M.name = function(config, node, state)
local highlight = config.highlight or highlights.FILE_NAME local highlight = config.highlight or highlights.FILE_NAME
local text = node.name local text = node.name
if node.type == "tutle" then if node.type == "title" then
text = ":: " .. node.name .. " ::" text = ":: " .. node.name .. " ::"
highlight = highlights.PREVIEW highlight = highlights.PREVIEW
elseif node.type == "root" then elseif node.type == "root" then