diff --git a/lua/telescope/_extensions/macrothis.lua b/lua/telescope/_extensions/macrothis.lua index c47e695..1e4ca45 100644 --- a/lua/telescope/_extensions/macrothis.lua +++ b/lua/telescope/_extensions/macrothis.lua @@ -170,7 +170,8 @@ local delete_macro = function(prompt_bufnr) { prompt = "Confirm deletion? [y/n]: " }, function(confirmation) if - string.len(confirmation) == 0 + not confirmation + or string.len(confirmation) == 0 or string.sub(string.lower(confirmation), 0, 1) ~= "y" then print("cancelled")