diff options
| author | jdhao <jdhao@hotmail.com> | 2021-08-14 01:23:43 +0800 |
|---|---|---|
| committer | jdhao <jdhao@hotmail.com> | 2021-08-14 01:23:43 +0800 |
| commit | 07c80f948df52deff38f5b838b4a0dc42b683cdb (patch) | |
| tree | d349926dac605a064b8ca40d3c6c6a8031d2ee92 /lua/config/lsp.lua | |
| parent | 42d3c49fea1f0daf6aa86ac557e3b1b9a0fcbcbe (diff) | |
Use proper true or false value for boolean variables
In lua, 0 and empty string is true, which is counter-intuitive and
different from vim script. So we need to use proper boolean type for vim
script global variables, instead of numbers.
Diffstat (limited to 'lua/config/lsp.lua')
| -rw-r--r-- | lua/config/lsp.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lua/config/lsp.lua b/lua/config/lsp.lua index 1cae961..4279a6e 100644 --- a/lua/config/lsp.lua +++ b/lua/config/lsp.lua @@ -109,7 +109,7 @@ lspconfig.vimls.setup{ } local sumneko_binary_path = vim.fn.exepath('lua-language-server') -if vim.g.is_mac > 0 or vim.g.is_linux > 0 and sumneko_binary_path ~= '' then +if vim.g.is_mac or vim.g.is_linux and sumneko_binary_path ~= '' then local sumneko_root_path = vim.fn.fnamemodify(sumneko_binary_path, ':h:h:h') local runtime_path = vim.split(package.path, ';') |
