We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 99654fe commit b9300fbCopy full SHA for b9300fb
lua/copilot/client.lua
@@ -103,7 +103,12 @@ function M.buf_attach(force)
103
local bufnr = vim.api.nvim_get_current_buf()
104
local bufname = vim.api.nvim_buf_get_name(bufnr)
105
106
- if not force and not M.should_attach(bufnr, bufname) and not util.should_attach() then
+ -- if force or (M.should_attach and M.should_attach(bufnr, bufname)) then
107
+ -- do stuff
108
+ -- end
109
+
110
+ if not (force or (M.should_attach(bufnr, bufname) and util.should_attach())) then
111
+ logger.debug("not attaching to buffer based on force and should_attach criteria")
112
return
113
end
114
0 commit comments