From efa0b1fe7363a7b7890b5b232b346a8d338f88f7 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Thu, 5 Mar 2026 23:57:05 -0500 Subject: [PATCH] fix(compiler): split nil guard in `M.stop` for type narrowing --- lua/preview/compiler.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/preview/compiler.lua b/lua/preview/compiler.lua index 72bb8c8..b7f8983 100644 --- a/lua/preview/compiler.lua +++ b/lua/preview/compiler.lua @@ -412,7 +412,7 @@ end ---@param bufnr integer function M.stop(bufnr) local s = state[bufnr] - if not (s and s.process) then + if not s or not s.process then return end log.dbg('stopping process for buffer %d', bufnr)