diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-11-08 11:44:04 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-11-08 11:44:04 +0800 |
commit | 444851fc1adb2fe3a0f952807cb4b644e18790c1 (patch) | |
tree | 722586a59027734fbba91678e51d82061c3a923b /server-beta/src/core | |
parent | d2b9dee8ce0ae345e4efd43c112bb3efd4071888 (diff) | |
download | lua-language-server-444851fc1adb2fe3a0f952807cb4b644e18790c1.zip |
修正一些bug
Diffstat (limited to 'server-beta/src/core')
-rw-r--r-- | server-beta/src/core/diagnostics/global-in-nil-env.lua | 2 | ||||
-rw-r--r-- | server-beta/src/core/diagnostics/init.lua | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/server-beta/src/core/diagnostics/global-in-nil-env.lua b/server-beta/src/core/diagnostics/global-in-nil-env.lua index 72375ea5..d8cc0075 100644 --- a/server-beta/src/core/diagnostics/global-in-nil-env.lua +++ b/server-beta/src/core/diagnostics/global-in-nil-env.lua @@ -50,7 +50,7 @@ return function (uri, callback) finish = source.finish, uri = uri, message = lang.script.DIAG_GLOBAL_IN_NIL_ENV, - relative = { + related = { { start = ok.start, finish = ok.finish, diff --git a/server-beta/src/core/diagnostics/init.lua b/server-beta/src/core/diagnostics/init.lua index 8b6167cc..2972694d 100644 --- a/server-beta/src/core/diagnostics/init.lua +++ b/server-beta/src/core/diagnostics/init.lua @@ -7,8 +7,9 @@ local function check(uri, name, level, results) return end level = config.config.diagnostics.severity[name] or level + local severity = define.DiagnosticSeverity[level] require('core.diagnostics.' .. name)(uri, function (result) - result.level = level or result.level + result.level = severity or result.level result.code = name results[#results+1] = result end, name) |