aboutsummaryrefslogtreecommitdiff
path: root/lua/cmake-explorer/notification.lua
blob: fa8ff6ea8f560785e2cfbdd9c262b4afd47b0b1c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
local has_notify, notify = pcall(require, "notify")

local Notification = {}

function Notification.notify(msg, lvl, opts)
  opts = opts or {}
  if has_notify then
    opts.hide_from_history = true
    return notify(msg, lvl, opts)
  end
end

return Notification