From a67da00e8e2b61a2fa197188b7ffb3e3b83a2a74 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Thu, 21 Mar 2019 15:41:59 +0800 Subject: =?UTF-8?q?=E6=9B=B4=E5=8A=A0=E5=87=86=E7=A1=AE=E7=9A=84=E5=88=86?= =?UTF-8?q?=E8=AF=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/src/core/signature.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'server/src/core/signature.lua') diff --git a/server/src/core/signature.lua b/server/src/core/signature.lua index 3e551e38..1e629308 100644 --- a/server/src/core/signature.lua +++ b/server/src/core/signature.lua @@ -68,8 +68,8 @@ local function getHover(call, pos) end return function (vm, pos) - local source = findSource(vm, pos) - if source.type == 'string' then + local source = findSource(vm, pos) or findSource(vm, pos-1) + if not source or source.type == 'string' then return end local calls = findCall(vm, pos) -- cgit v1.2.3