diff options
-rw-r--r-- | server/src/workspace.lua | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/server/src/workspace.lua b/server/src/workspace.lua index 4ab8b6d2..01532c7a 100644 --- a/server/src/workspace.lua +++ b/server/src/workspace.lua @@ -268,8 +268,8 @@ function mt:matchPath(baseUri, input) end function mt:searchPath(baseUri, str) - if self.searched[str] then - return self.searched[str] + if self.searched[baseUri] and self.searched[baseUri][str] then + return self.searched[baseUri][str] end str = str:gsub('%.', '/') local searchers = {} @@ -279,7 +279,10 @@ function mt:searchPath(baseUri, str) local uri = self:findPath(baseUri, searchers) if uri then - self.searched[str] = uri + if not self.searched[baseUri] then + self.searched[baseUri] = {} + end + self.searched[baseUri][str] = uri end return uri end |