diff --git a/lua/telescope/actions/init.lua b/lua/telescope/actions/init.lua
index 7e0053a..1f047e2 100644
--- a/lua/telescope/actions/init.lua
+++ b/lua/telescope/actions/init.lua
@@ -1128,7 +1128,7 @@ actions.which_key = function(prompt_bufnr, opts)
name = name == "" and action or name .. " + " .. action
end
end
- if name and name ~= "which_key" then
+ if name and name ~= "which_key" and name ~= "nop" then
if not opts.only_show_current_mode or mode == v.mode then
table.insert(mappings, { mode = v.mode, keybind = v.keybind, name = name })
end
@@ -1289,6 +1289,8 @@ actions.to_fuzzy_refine = function(prompt_bufnr)
})
end
+actions.nop = function(_) end
+
-- ==================================================
-- Transforms modules and sets the correct metatables.
-- ==================================================
diff --git a/lua/telescope/mappings.lua b/lua/telescope/mappings.lua
index 66a7812..e5b23bc 100644
--- a/lua/telescope/mappings.lua
+++ b/lua/telescope/mappings.lua
@@ -157,6 +157,9 @@ mappings.default_mappings = config.values.default_mappings
[""] = actions.which_key,
[""] = actions.which_key, -- keys from pressing
[""] = { "", type = "command" },
+
+ -- disable c-j because we dont want to allow new lines #2123
+ [""] = actions.nop,
},
n = {