1 files changed,
11 insertions(+),
2 deletions(-)
Author:
Smirnov Oleksandr
ss2316544@gmail.com
Committed at:
2022-06-27 14:30:02 +0300
Parent:
2adbb49
M
lua/gopher/_utils/init.lua
@@ -38,10 +38,19 @@ return false
end, ---@param msg string - ---@param lvl string + ---@param lvl string|integer notify = function(msg, lvl) + local l + if lvl == "error" or lvl == 4 then + l = vim.log.levels.ERROR + elseif lvl == "info" or lvl == 2 then + l = vim.log.levels.INFO + elseif lvl == "debug" or lvl == 1 then + l = vim.log.levels.DEBUG + end + vim.defer_fn(function() - vim.notify(msg, lvl) + vim.notify(msg, l) end, 0) end, }