summaryrefslogtreecommitdiff
path: root/script/files.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2021-02-22 12:06:27 +0800
committer最萌小汐 <sumneko@hotmail.com>2021-02-22 12:06:27 +0800
commit5ab18375ca7f1b47fc589c30d419b23627e1a91f (patch)
tree2b5a0a5e07c44b6ec05b6d9a3650d66ae1fb1a22 /script/files.lua
parentf0003c7e75767e42b34d24be6ce24bf90ead04cf (diff)
downloadlua-language-server-5ab18375ca7f1b47fc589c30d419b23627e1a91f.zip
fix runtime errors
Diffstat (limited to 'script/files.lua')
-rw-r--r--script/files.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/script/files.lua b/script/files.lua
index af6be58c..6dab8a01 100644
--- a/script/files.lua
+++ b/script/files.lua
@@ -39,6 +39,9 @@ m.astMap = setmetatable({}, { __mode = 'v' })
local uriMap = {}
local function getUriKey(uri)
+ if not uri then
+ return nil
+ end
if not uriMap[uri] then
if platform.OS == 'Windows' then
uriMap[uri] = uri:lower()