summaryrefslogtreecommitdiff
path: root/server/src/method/textDocument/definition.lua
diff options
context:
space:
mode:
Diffstat (limited to 'server/src/method/textDocument/definition.lua')
-rw-r--r--server/src/method/textDocument/definition.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/server/src/method/textDocument/definition.lua b/server/src/method/textDocument/definition.lua
index 1f21d67d..0df5c522 100644
--- a/server/src/method/textDocument/definition.lua
+++ b/server/src/method/textDocument/definition.lua
@@ -1,6 +1,9 @@
local matcher = require 'matcher'
local function checkWorkSpaceComplete(lsp, result)
+ if result.type ~= 'field' and result.type ~= 'local' then
+ return
+ end
if result.value then
if not result.value.isRequire then
return