diff options
Diffstat (limited to 'lua/startup')
-rw-r--r-- | lua/startup/functions.lua | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/lua/startup/functions.lua b/lua/startup/functions.lua index ef9816e..63c26df 100644 --- a/lua/startup/functions.lua +++ b/lua/startup/functions.lua @@ -17,12 +17,16 @@ end ---Returns a string with the number of loaded Packer Plugins ---@return string: String with info about the number of loaded plugins function functions.packer_plugins() - return { - string.format( - "Total plugins (packer.nvim): %d", - vim.tbl_count(packer_plugins) - ), - } + if packer_plugins then + return { + string.format( + "Total plugins (packer.nvim): %d", + vim.tbl_count(packer_plugins) + ), + } + else + return "" + end end ---Returns the current date and time |