diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2018-11-30 15:34:22 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2018-11-30 15:34:22 +0800 |
commit | 136fe2532b763534c24714db677b12405a1b3712 (patch) | |
tree | e920567ab85d5fa1e2228d59ef919c71675ebcbe /server/src/matcher/definition.lua | |
parent | 71a267d42d6a28dcf1333092d57714f274fc698d (diff) | |
download | lua-language-server-136fe2532b763534c24714db677b12405a1b3712.zip |
修正bug
Diffstat (limited to 'server/src/matcher/definition.lua')
-rw-r--r-- | server/src/matcher/definition.lua | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/server/src/matcher/definition.lua b/server/src/matcher/definition.lua index a7e51121..236e4924 100644 --- a/server/src/matcher/definition.lua +++ b/server/src/matcher/definition.lua @@ -65,10 +65,10 @@ function mt:getField(parent, key, source) if parent == nil or key == nil then return nil end - if not parent.childs then - return nil + local var + if parent.childs then + var = parent.childs[key] end - local var = parent.childs[key] if not var then var = self:addField(parent, key, source) end @@ -100,7 +100,6 @@ function mt:checkDots(dots) type = 'dots', dots = dots, } - self.stop = true end end end @@ -403,9 +402,6 @@ end function mt:searchActions(actions) for _, action in ipairs(actions) do self:searchAction(action) - if self.stop then - return self.result - end end return nil end |