refactor(utils): log notifications
This commit is contained in:
parent
517150e5c2
commit
a2710261bf
1 changed files with 4 additions and 0 deletions
|
|
@ -1,3 +1,5 @@
|
||||||
|
local c = require "gopher.config"
|
||||||
|
local log = require "gopher._utils.log"
|
||||||
local utils = {}
|
local utils = {}
|
||||||
|
|
||||||
---@param msg string
|
---@param msg string
|
||||||
|
|
@ -7,6 +9,7 @@ function utils.deferred_notify(msg, lvl)
|
||||||
vim.notify(msg, lvl, {
|
vim.notify(msg, lvl, {
|
||||||
title = c.___plugin_name,
|
title = c.___plugin_name,
|
||||||
})
|
})
|
||||||
|
log.info(msg)
|
||||||
end, 0)
|
end, 0)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
@ -17,6 +20,7 @@ function utils.notify(msg, lvl)
|
||||||
vim.notify(msg, lvl, {
|
vim.notify(msg, lvl, {
|
||||||
title = c.___plugin_name,
|
title = c.___plugin_name,
|
||||||
})
|
})
|
||||||
|
log.info(msg)
|
||||||
end
|
end
|
||||||
|
|
||||||
-- safe require
|
-- safe require
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue