From 024414366e1dbdfa804d0f71fac53c0246490b4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Tue, 25 Dec 2018 15:29:22 +0800 Subject: =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/src/matcher/hover.lua | 2 +- server/src/matcher/signature.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'server/src/matcher') diff --git a/server/src/matcher/hover.lua b/server/src/matcher/hover.lua index a6a83ed5..e34bec69 100644 --- a/server/src/matcher/hover.lua +++ b/server/src/matcher/hover.lua @@ -401,7 +401,7 @@ return function (result, source, lsp, select) return getStringHover(result, lsp) end - if result.type ~= 'local' or result.type ~= 'field' then + if result.type ~= 'local' and result.type ~= 'field' then return end diff --git a/server/src/matcher/signature.lua b/server/src/matcher/signature.lua index c62117fc..dc6af15e 100644 --- a/server/src/matcher/signature.lua +++ b/server/src/matcher/signature.lua @@ -53,7 +53,7 @@ return function (vm, pos) local hovers = {} for _, call in ipairs(calls) do local hvr = hover(call.var, call.source, nil, call.select) - if hvr.argLabel then + if hvr and hvr.argLabel then hovers[#hovers+1] = hvr end end -- cgit v1.2.3