plugins/nvim-cmp: do not pass in enabled = true (#324)

Since this means cmp is active in prompts, e.g. telescope

https://www.reddit.com/r/neovim/comments/vtw4vl/disable_nvimcmp_in_telescopes_buffer/
This commit is contained in:
Thomas Christensen 2023-04-07 22:39:37 +02:00 committed by GitHub
parent d7967f3ffd
commit 5d2dbc40a6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -463,7 +463,13 @@ in {
config = let
options = {
enabled = cfg.enable;
# The upstream default value (which is a function) should not be overwritten.
# https://www.reddit.com/r/neovim/comments/vtw4vl/comment/if9zfdf/?utm_source=share&utm_medium=web2x&context=3
enabled =
if cfg.enable
then null
else false;
performance = cfg.performance;
preselect =
helpers.ifNonNull' cfg.preselect