diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2020-01-23 16:09:48 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2020-01-23 16:09:48 +0800 |
commit | 0a5fbd8a8889599b2216c674819569eda754ef05 (patch) | |
tree | e3900c5ea88e822bbac6e0c137f0c3231c07ada8 /script-beta/vm/getClass.lua | |
parent | 5597c4449838ad4bfae4c2791c0778e9b7fd08ab (diff) | |
download | lua-language-server-0a5fbd8a8889599b2216c674819569eda754ef05.zip |
修正报错
Diffstat (limited to 'script-beta/vm/getClass.lua')
-rw-r--r-- | script-beta/vm/getClass.lua | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/script-beta/vm/getClass.lua b/script-beta/vm/getClass.lua index c4bde74a..4d7ef69c 100644 --- a/script-beta/vm/getClass.lua +++ b/script-beta/vm/getClass.lua @@ -6,6 +6,9 @@ local function getClass(source, classes, deep) end vm.eachField(source, function (src) local key = vm.getKeyName(src) + if not key then + return + end local lkey = key:lower() if lkey == 's|type' or lkey == 's|__name' @@ -19,6 +22,9 @@ local function getClass(source, classes, deep) if source.value then vm.eachField(source.value, function (src) local key = vm.getKeyName(src) + if not key then + return + end local lkey = key:lower() if lkey == 's|type' or lkey == 's|__name' |