summaryrefslogtreecommitdiff
path: root/script/proto
diff options
context:
space:
mode:
authoruhziel <uhziel@gmail.com>2020-12-14 11:10:03 +0800
committeruhziel <uhziel@gmail.com>2020-12-14 11:10:03 +0800
commitf05b8a9b522989e83f28ce0511d5468d7300b40d (patch)
tree56b515671335acb8fc63709529deda255497a47c /script/proto
parentcbacf3202f6162073aad1433ef0197b7b16f79bc (diff)
parent035f4393ab98b0de30650af94375d9c5e2fe07c1 (diff)
downloadlua-language-server-f05b8a9b522989e83f28ce0511d5468d7300b40d.zip
合并 master 中的提交
Diffstat (limited to 'script/proto')
-rw-r--r--script/proto/proto.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/script/proto/proto.lua b/script/proto/proto.lua
index a0758ac3..944268c2 100644
--- a/script/proto/proto.lua
+++ b/script/proto/proto.lua
@@ -106,7 +106,7 @@ function m.doMethod(proto)
local ok = true
local res
-- 任务可能在执行过程中被中断,通过close来捕获
- local response <close> = util.defer(function ()
+ local response <close> = function ()
local passed = os.clock() - clock
if passed > 0.2 then
log.debug(('Method [%s] takes [%.3f]sec.'):format(method, passed))
@@ -120,7 +120,7 @@ function m.doMethod(proto)
else
m.responseErr(proto.id, define.ErrorCodes.InternalError, res)
end
- end)
+ end
ok, res = xpcall(abil, log.error, proto.params)
end)
end