From 675a72e2e8be503b9d3d2cd4594ed07ea31bb975 Mon Sep 17 00:00:00 2001 From: hrsh7th Date: Fri, 3 Sep 2021 21:29:53 +0900 Subject: [PATCH] Check configuration --- lua/cmp/core.lua | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lua/cmp/core.lua b/lua/cmp/core.lua index 451e0a2..1b5dd3f 100644 --- a/lua/cmp/core.lua +++ b/lua/cmp/core.lua @@ -35,6 +35,11 @@ core.menu = menu.new({ ---@param e cmp.Entry core.ghost_text = function(e) vim.api.nvim_buf_clear_namespace(0, core.GHOST_TEXT_NS, 0, -1) + + if not config.get().experimental.ghost_text then + return + end + if not e then return end