Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lua/CopilotChat/ui/chat.lua
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ local function match_block_header(header)
if path then
return type, path, tonumber(start_line) or 1, tonumber(end_line) or tonumber(start_line) or 1
elseif type then
return type, 'block'
return type, nil
end
end
end
Expand Down Expand Up @@ -801,7 +801,7 @@ function Chat:render()
local header = block.header
local filetype = header.filetype
local filename = header.filename
local text = string.format('[%s] %s', filetype, filename)
local text = string.format('[%s] %s', filetype, filename or 'block')
if header.start_line and header.end_line then
text = text .. string.format(' lines %d-%d', header.start_line, header.end_line)
end
Expand Down
Loading