summaryrefslogtreecommitdiff
path: root/server/src/method
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2019-04-05 19:06:24 +0800
committer最萌小汐 <sumneko@hotmail.com>2019-04-05 19:06:24 +0800
commit5ed7ded384aca2cff4d09401cc852f7943a1ea94 (patch)
tree0121fe277a85d0b85bd34881c83cd6b3789193f1 /server/src/method
parent8cd1514556324eabcf1b96954afe53adfc2030b7 (diff)
downloadlua-language-server-5ed7ded384aca2cff4d09401cc852f7943a1ea94.zip
修改描述
Diffstat (limited to 'server/src/method')
-rw-r--r--server/src/method/textDocument/publishDiagnostics.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/server/src/method/textDocument/publishDiagnostics.lua b/server/src/method/textDocument/publishDiagnostics.lua
index fbe65bb3..f2e1a593 100644
--- a/server/src/method/textDocument/publishDiagnostics.lua
+++ b/server/src/method/textDocument/publishDiagnostics.lua
@@ -1,5 +1,6 @@
local core = require 'core'
local lang = require 'language'
+local config = require 'config'
local DiagnosticSeverity = {
Error = 1,
@@ -84,9 +85,9 @@ local function buildError(err, lines, uri)
}
if err.version then
if type(err.version) == 'table' then
- diagnostic.message = ('%s(%s)'):format(diagnostic.message, lang.script('DIAG_NEED_VERSION', table.concat(err.version, '/')))
+ diagnostic.message = ('%s(%s)'):format(diagnostic.message, lang.script('DIAG_NEED_VERSION', table.concat(err.version, '/'), config.config.runtime.version))
else
- diagnostic.message = ('%s(%s)'):format(diagnostic.message, lang.script('DIAG_NEED_VERSION', err.version))
+ diagnostic.message = ('%s(%s)'):format(diagnostic.message, lang.script('DIAG_NEED_VERSION', err.version, config.config.runtime.version))
end
end
if err.level == 'error' then