diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2022-02-16 15:22:45 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2022-02-16 15:22:45 +0800 |
commit | 30bc6d37b823cab58114ea09c3f6388c6ef30b02 (patch) | |
tree | 18fa3cf12eafe6b06bf2eb60b08302311a3b2698 /script/core/diagnostics/undefined-field.lua | |
parent | 8f2c4227753f300e717fa218d915c281dbc3e175 (diff) | |
parent | 12d6a9eb75f31b64cbc89eb3265805bc8dad01f0 (diff) | |
download | lua-language-server-30bc6d37b823cab58114ea09c3f6388c6ef30b02.zip |
Merge commit '12d6a9eb75f31b64cbc89eb3265805bc8dad01f0' into 3.0
Diffstat (limited to 'script/core/diagnostics/undefined-field.lua')
-rw-r--r-- | script/core/diagnostics/undefined-field.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/script/core/diagnostics/undefined-field.lua b/script/core/diagnostics/undefined-field.lua index b456ef9a..ea15dcda 100644 --- a/script/core/diagnostics/undefined-field.lua +++ b/script/core/diagnostics/undefined-field.lua @@ -4,7 +4,7 @@ local lang = require 'language' local guide = require 'parser.guide' local await = require 'await' -local SkipCheckClass = { +local skipCheckClass = { ['unknown'] = true, ['any'] = true, ['table'] = true, @@ -48,7 +48,7 @@ return function (uri, callback) local ok for _, def in ipairs(defs) do if def.type == 'doc.class.name' - and not SkipCheckClass[def[1]] then + and not skipCheckClass[def[1]] then ok = true break end @@ -59,7 +59,7 @@ return function (uri, callback) end end local message = lang.script('DIAG_UNDEF_FIELD', guide.getKeyName(src)) - if src.type == 'getfield' and src.field then + if src.type == 'getfield' and src.field then callback { start = src.field.start, finish = src.field.finish, |