From e16aa866507a3fc4dad2b83c7048d073fc3e72f6 Mon Sep 17 00:00:00 2001 From: Ivan Danyliuk Date: Sun, 22 May 2022 21:09:28 +0300 Subject: [PATCH] Hide Flutter dev log from buffers list. --- lua/flutter-tools/log.lua | 1 + lua/flutter-tools/utils/init.lua | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lua/flutter-tools/log.lua b/lua/flutter-tools/log.lua index 17edf53f..b4335479 100644 --- a/lua/flutter-tools/log.lua +++ b/lua/flutter-tools/log.lua @@ -110,6 +110,7 @@ function M.__resurrect() vim.bo[buf].modifiable = false vim.bo[buf].modified = false vim.bo[buf].buftype = "nofile" + vim.bo[buf].buflisted = false end function M.clear() diff --git a/lua/flutter-tools/utils/init.lua b/lua/flutter-tools/utils/init.lua index 07c06ef9..8549b5f1 100644 --- a/lua/flutter-tools/utils/init.lua +++ b/lua/flutter-tools/utils/init.lua @@ -46,7 +46,7 @@ function M.buf_valid(bufnr, name) if bufnr then return api.nvim_buf_is_loaded(bufnr) end - return vim.fn.bufexists(target) > 0 and vim.fn.buflisted(target) > 0 + return vim.fn.bufexists(target) > 0 end ---Add a function to the global callback map