show only filename if icon == nil
This commit is contained in:
@@ -22,6 +22,10 @@ local filename = {
|
|||||||
local fileext = vim.fn.expand("%:e")
|
local fileext = vim.fn.expand("%:e")
|
||||||
local icon = require("nvim-web-devicons").get_icon(filename, fileext)
|
local icon = require("nvim-web-devicons").get_icon(filename, fileext)
|
||||||
|
|
||||||
|
if not icon then
|
||||||
|
return filename
|
||||||
|
end
|
||||||
|
|
||||||
return icon .. " " .. filename
|
return icon .. " " .. filename
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user