diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2022-04-16 00:31:50 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2022-04-16 00:31:50 +0800 |
commit | 8b315d6f1d1ed2e680014841b84c3a768a136bd9 (patch) | |
tree | f8b503cd248528a2c1c4e79a4a0e0ce7cc60acb9 /script/provider/semantic-tokens.lua | |
parent | 8b5c02c49fa397a40f03dc5c27dd6872dee13b2c (diff) | |
download | lua-language-server-8b315d6f1d1ed2e680014841b84c3a768a136bd9.zip |
fix refresh
Diffstat (limited to 'script/provider/semantic-tokens.lua')
-rw-r--r-- | script/provider/semantic-tokens.lua | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/script/provider/semantic-tokens.lua b/script/provider/semantic-tokens.lua index 80416fff..0218db2a 100644 --- a/script/provider/semantic-tokens.lua +++ b/script/provider/semantic-tokens.lua @@ -3,14 +3,13 @@ local client = require 'client' local json = require "json" local config = require 'config' -if not client.getAbility 'workspace.semanticTokens.refreshSupport' then - return -end - local function refresh() if not client.isReady() then return end + if not client.getAbility 'workspace.semanticTokens.refreshSupport' then + return + end log.debug('Refresh semantic tokens.') proto.request('workspace/semanticTokens/refresh', json.null) end |