chore(config): add silent_warning options (#378)

Signed-off-by: Aaron Pham <contact@aarnphm.xyz>
This commit is contained in:
Aaron Pham
2024-08-29 17:08:39 -04:00
committed by GitHub
parent bd500feeec
commit b43377c044
2 changed files with 31 additions and 13 deletions

View File

@@ -321,6 +321,10 @@ end
---@param msg string|string[]
---@param opts? LazyNotifyOpts
function M.warn(msg, opts)
if require("avante.config").options.silent_warning then
return
end
opts = opts or {}
opts.level = vim.log.levels.WARN
M.notify(msg, opts)