From 1732f94add37ad503d23701f259285629048bf0c Mon Sep 17 00:00:00 2001 From: alemi Date: Sat, 7 Sep 2024 03:37:51 +0200 Subject: [PATCH] fix(neotree): remove extra spacer, access root array --- lua/codemp/neo-tree/bridge.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lua/codemp/neo-tree/bridge.lua b/lua/codemp/neo-tree/bridge.lua index 0d7eada..04d516e 100644 --- a/lua/codemp/neo-tree/bridge.lua +++ b/lua/codemp/neo-tree/bridge.lua @@ -96,7 +96,6 @@ M.update_state = function(state) new_root("users"), spacer(), } - table.insert(root.children, spacer()) for i, path in ipairs(codemp.workspace:filetree()) do table.insert(root[1].children, new_item(codemp.workspace.name, path)) end @@ -106,7 +105,7 @@ M.update_state = function(state) elseif codemp.client ~= nil then root = { new_root(codemp.client.username .. "@codemp") } for _, ws in ipairs(codemp.available) do - table.insert(root.children, new_workspace(ws.name, ws.owned)) + table.insert(root[1].children, new_workspace(ws.name, ws.owned)) end else root = { new_root("codemp") }