Skip to content

Commit

Permalink
fix: escape filename after it has been shortened
Browse files Browse the repository at this point in the history
  • Loading branch information
ozymohliad committed Nov 30, 2023
1 parent 2248ef2 commit 43bb258
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lua/lualine/components/filename.lua
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,6 @@ M.update_status = function(self)
data = vim.fn.expand('%:t')
end

data = modules.utils.stl_escape(data)

if data == '' then
data = self.options.symbols.unnamed
end
Expand All @@ -113,6 +111,8 @@ M.update_status = function(self)
table.insert(symbols, self.options.symbols.newfile)
end

data = modules.utils.stl_escape(data)

return data .. (#symbols > 0 and ' ' .. table.concat(symbols, '') or '')
end

Expand Down

0 comments on commit 43bb258

Please sign in to comment.