Skip to content

Commit

Permalink
Removes redundant code
Browse files Browse the repository at this point in the history
  • Loading branch information
alycklama committed Mar 30, 2024
1 parent d914f42 commit 1199f9b
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions lua/telescope/make_entry.lua
Original file line number Diff line number Diff line change
Expand Up @@ -162,19 +162,9 @@ do

display, hl_group, icon = utils.transform_devicons(entry.value, display, disable_devicons)

local function get_offset()
local offset = 0

if hl_group then
offset = #icon + 1
end

return offset
end

if hl_group then
local style = { { { 0, get_offset() }, hl_group } }
style = utils.merge_styles(style, path_style, get_offset())
local style = { { { 0, #icon + 1 }, hl_group } }
style = utils.merge_styles(style, path_style, #icon + 1)
return display, style
else
return display, path_style
Expand Down

0 comments on commit 1199f9b

Please sign in to comment.