diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2021-04-07 16:34:56 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2021-04-07 16:34:56 +0800 |
commit | 65cc77a8f6dfe7bfaac51cc6245f0de9efbac72a (patch) | |
tree | 64a1cc91ddc3be4147a03dce3b92f3d9ec648295 /script | |
parent | d0eee5555d407d4ef4b3fac5cc6be9789ff0d77a (diff) | |
download | lua-language-server-65cc77a8f6dfe7bfaac51cc6245f0de9efbac72a.zip |
fix #497
Diffstat (limited to 'script')
-rw-r--r-- | script/provider/provider.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/script/provider/provider.lua b/script/provider/provider.lua index 11b87405..65993940 100644 --- a/script/provider/provider.lua +++ b/script/provider/provider.lua @@ -458,7 +458,7 @@ proto.on('textDocument/completion', function (params) if not files.exists(uri) then return nil end - if config.other.acceptSuggestionOnEnter ~= 'off' then + if params.context and config.other.acceptSuggestionOnEnter ~= 'off' then if params.context.triggerCharacter == '\n' or params.context.triggerCharacter == '{' or params.context.triggerCharacter == ',' then |