nvim-cmp
nvim-cmp copied to clipboard
fix(utils): Only call callback if type(callback) == "function"
Sometimes the cursor freezes for a second and i get a error popup:
Error executing lua callback: ....../event.lua:47: attempt to call local 'callback' ( a table value )
Stack traceback:
....
so i fixed this, it's only a 3 line change
i don't know what caused this issue (shouldn't happen)
but either way it makes way more sense to just make this a type(callback)=="function" check