summaryrefslogtreecommitdiff
path: root/script-beta
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2019-12-10 19:18:34 +0800
committer最萌小汐 <sumneko@hotmail.com>2019-12-10 19:18:34 +0800
commit244d00ba67e30d28b9c835fc04a09ca3e98e9a20 (patch)
treef6f600c4c3076e7995dc9eb06938dfa5a0fa54d8 /script-beta
parente642773d31b415ff79c6a682486a3e7aaa2f8a86 (diff)
downloadlua-language-server-244d00ba67e30d28b9c835fc04a09ca3e98e9a20.zip
任务被提前中断时,视为执行成功
Diffstat (limited to 'script-beta')
-rw-r--r--script-beta/proto/proto.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/script-beta/proto/proto.lua b/script-beta/proto/proto.lua
index 7b6b0087..b70cc451 100644
--- a/script-beta/proto/proto.lua
+++ b/script-beta/proto/proto.lua
@@ -97,7 +97,8 @@ function m.doMethod(proto)
await.create(function ()
log.debug('Start method:', method)
local clock = os.clock()
- local ok, res
+ local ok = true
+ local res
-- 任务可能在执行过程中被中断,通过close来捕获
local response <close> = util.defer(function ()
local passed = os.clock() - clock