Skip to content

Commit 7252d9c

Browse files
committed
fix: handle relative roots correctly
1 parent 45deec9 commit 7252d9c

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

script/workspace/workspace.lua

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -438,8 +438,11 @@ function m.findUrisByDofile(path, sourceUri)
438438
end
439439

440440
for _, root in ipairs(roots) do
441-
local rootUri = furi.encode(root)
442-
addResult(m.getAbsolutePath(rootUri, path))
441+
local rootPath = m.getAbsolutePath(sourceUri or m.rootUri, root)
442+
if rootPath then
443+
local rootUri = furi.encode(rootPath)
444+
addResult(m.getAbsolutePath(rootUri, path))
445+
end
443446
end
444447

445448
if m.rootUri then

0 commit comments

Comments
 (0)