romgrk / barbar.nvim

The neovim tabline plugin.
2.26k stars 85 forks source link

fix: close click confirmation message reports error #450

Closed Iron-E closed 1 year ago

Iron-E commented 1 year ago

Certain buffers show a message when trying to close them (e.g. :terminals) if you do not :confirm their closure. This was getting picked up by the bbye (since it is not a v:errmsg).

To fix it, I have switched from using v:errmsg to the pcall's result return value.

However, if we left it at that, it would be impossible to click to close certain windows (since they need :confirm). Thus I have added :confirm as a modifier to the close click handler.


Closes #449.