Skip to content

Commit

Permalink
bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
ccaglak committed Oct 19, 2024
1 parent cccddc0 commit 9743afa
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions lua/namespace/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -296,16 +296,22 @@ local function process_file_search(class_entry, prefix, workspace_root, current_
end

local function process_single_class(class_entry, prefix, workspace_root, current_directory, callback)
local classmap_results = search_autoload_classmap({ class_entry })
if classmap_results[class_entry.name] then
local paths = classmap_results[class_entry.name]
if type(paths) == "table" then
if process_classmap_results(paths, class_entry.name, prefix, workspace_root, current_directory, callback) then
return
process_file_search(class_entry, prefix, workspace_root, current_directory, function(file_result)
if file_result then
callback(file_result)
else
local classmap_results = search_autoload_classmap({ class_entry })
if classmap_results[class_entry.name] then
local paths = classmap_results[class_entry.name]
if type(paths) == "table" then
if process_classmap_results(paths, class_entry.name, prefix, workspace_root, current_directory, callback) then
return
end
end
end
callback(nil)
end
end
process_file_search(class_entry, prefix, workspace_root, current_directory, callback)
end)
end

local function process_class_queue(queue, prefix, workspace_root, current_directory, callback)
Expand Down

0 comments on commit 9743afa

Please sign in to comment.