refactor(#2829): multi instance nvim-tree.explorer.sorters (#2835)

* refactor: multi instance nvim-tree.explorer.sorters

* fix: linter errors

* fix: style

* fix: according to code review

* chore: removed comment

* fix: missing cfg params in sorters

* tidy following rebase

* tidy following rebase

---------

Co-authored-by: Alexander Courtis <alex@courtis.org>
This commit is contained in:
Mateusz Russak
2024-07-27 05:54:40 +02:00
committed by GitHub
parent 908478a0e0
commit 82ba116bbd
4 changed files with 53 additions and 48 deletions

View File

@@ -2,7 +2,6 @@ local utils = require "nvim-tree.utils"
local builders = require "nvim-tree.explorer.node-builders"
local explorer_node = require "nvim-tree.explorer.node"
local git = require "nvim-tree.git"
local sorters = require "nvim-tree.explorer.sorters"
local live_filter = require "nvim-tree.live-filter"
local log = require "nvim-tree.log"
@@ -82,7 +81,7 @@ function M.explore(node, status, parent)
return ns
end
sorters.sort(node.nodes)
parent.sorters:sort(node.nodes)
live_filter.apply_filter(node)
log.profile_end(profile)