diff --git a/lua/cmake-tools/quickfix.lua b/lua/cmake-tools/quickfix.lua index 946a0bd8..7297378a 100644 --- a/lua/cmake-tools/quickfix.lua +++ b/lua/cmake-tools/quickfix.lua @@ -69,9 +69,7 @@ function _quickfix.run(cmd, env_script, env, args, cwd, opts, on_exit, on_output _quickfix.scroll_to_bottom() end if code == 0 and opts.auto_close_when_success then - vim.defer_fn(function() - _quickfix.close(opts) - end, 100) + _quickfix.close(opts) end if on_exit ~= nil then on_exit(code)