fix(lualine): dont load copilot when not available. Fixes #872

This commit is contained in:
Folke Lemaitre committed 2023-06-02 07:39:22 +02:00
1 parent 9c1a5620ed
commit 5ed3250f24
1 file changed
+3
@@ -33,6 +33,9 @@ return {
return ok and #clients > 0
end,
color = function()
if not package.loaded["copilot"] then
return
end
local status = require("copilot.api").status.data
return colors[status.status] or colors[""]
end,