Bläddra i källkod

there was a weird situation that caused lualine msg to turn boolean instead of table (#1492)

Abouzar Parvan 3 år sedan
förälder
incheckning
151684bba1
1 ändrade filer med 2 tillägg och 1 borttagningar
  1. 2 1
      lua/core/lualine/components.lua

+ 2 - 1
lua/core/lualine/components.lua

@@ -84,7 +84,8 @@ return {
       msg = msg or "LS Inactive"
       local buf_clients = vim.lsp.buf_get_clients()
       if next(buf_clients) == nil then
-        if #msg == 0 then
+        -- TODO: clean up this if statement
+        if type(msg) == "boolean" or #msg == 0 then
           return "LS Inactive"
         end
         return msg