summaryrefslogtreecommitdiff
path: root/script/provider/provider.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-12-22 18:46:02 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-12-22 18:46:02 +0800
commit3278c8c0b54934ac61a8a98688ab94f45ba15a9b (patch)
treee7fd953c4e30842ef765e440333971fe3f5f271d /script/provider/provider.lua
parent1806600407c8bd62af96a1671b3a1c30f3839e89 (diff)
downloadlua-language-server-3278c8c0b54934ac61a8a98688ab94f45ba15a9b.zip
improve code-lens
Diffstat (limited to 'script/provider/provider.lua')
-rw-r--r--script/provider/provider.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/script/provider/provider.lua b/script/provider/provider.lua
index 51bdf531..f9f5fa29 100644
--- a/script/provider/provider.lua
+++ b/script/provider/provider.lua
@@ -924,6 +924,7 @@ m.register 'textDocument/codeLens' {
resolveProvider = true,
}
},
+ abortByFileUpdate = true,
---@async
function (params)
local uri = files.getRealUri(params.textDocument.uri)
@@ -959,7 +960,7 @@ m.register 'codeLens/resolve' {
function (codeLen)
local core = require 'core.code-lens'
local command = core.resolve(codeLen.data.uri, codeLen.data.id)
- codeLen.command = command
+ codeLen.command = command or converter.command('...', '', {})
return codeLen
end
}