From d4fb5c2a61d649aac04b24ab23eeb82915863597 Mon Sep 17 00:00:00 2001 From: Micah Halter Date: Tue, 12 Dec 2023 06:21:58 -0500 Subject: [PATCH] fix(condition): loosen validity check in `buffer_matches` --- lua/astroui/status/condition.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/astroui/status/condition.lua b/lua/astroui/status/condition.lua index 25df8a6..735f2b7 100644 --- a/lua/astroui/status/condition.lua +++ b/lua/astroui/status/condition.lua @@ -45,7 +45,7 @@ local buf_matchers = { function M.buffer_matches(patterns, bufnr, op) if not op then op = "or" end if not bufnr then bufnr = 0 end - if require("astrocore.buffer").is_valid(bufnr) then + if vim.api.nvim_buf_is_valid(bufnr) then for kind, pattern_list in pairs(patterns) do if buf_matchers[kind](pattern_list, bufnr) then if op == "or" then return true end