From b5875459c9c9adc11a2fc1fd25db484a5c03fea4 Mon Sep 17 00:00:00 2001 From: Kristijan Husak Date: Thu, 30 Jan 2025 15:38:14 +0100 Subject: [PATCH] fix: remove double ts parsing --- lua/orgmode/files/elements/table/init.lua | 1 - lua/orgmode/utils/treesitter/init.lua | 1 - 2 files changed, 2 deletions(-) diff --git a/lua/orgmode/files/elements/table/init.lua b/lua/orgmode/files/elements/table/init.lua index 18091c114..6cfc7ab45 100644 --- a/lua/orgmode/files/elements/table/init.lua +++ b/lua/orgmode/files/elements/table/init.lua @@ -34,7 +34,6 @@ end ---@param cursor? table ---@return OrgTable | nil function Table.from_current_node(cursor) - ts_utils.parse_current_file() -- Get node from last column so we are sure we can find the table. -- If column is less than indentation of table, we will miss it. if not cursor then diff --git a/lua/orgmode/utils/treesitter/init.lua b/lua/orgmode/utils/treesitter/init.lua index 9526151b3..de5dee0e4 100644 --- a/lua/orgmode/utils/treesitter/init.lua +++ b/lua/orgmode/utils/treesitter/init.lua @@ -54,7 +54,6 @@ end -- returns the nearest headline function M.closest_headline_node(cursor) - M.parse_current_file() local node = M.get_node_at_cursor(cursor) if not node then