Skip to content

Commit fd56736

Browse files
olimorriscleong14
authored andcommitted
Revert "fix(ui): respect opts.visible for non-"system" roles" (olimorris#1218)
Revert "fix(ui): respect opts.visible for non-"system" roles (olimorris#1204)" This reverts commit ef9cdc6.
1 parent 8b47f2b commit fd56736

File tree

1 file changed

+1
-1
lines changed
  • lua/codecompanion/strategies/chat

1 file changed

+1
-1
lines changed

lua/codecompanion/strategies/chat/ui.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ function UI:render(context, messages, opts)
235235

236236
local function add_messages_to_buf(msgs)
237237
for i, msg in ipairs(msgs) do
238-
if msg.role ~= config.constants.SYSTEM_ROLE and (msg.opts and msg.opts.visible ~= false) then
238+
if msg.role ~= config.constants.SYSTEM_ROLE or (msg.opts and msg.opts.visible ~= false) then
239239
-- For workflow prompts: Ensure main user role doesn't get spaced
240240
if i > 1 and self.last_role ~= msg.role and msg.role ~= config.constants.USER_ROLE then
241241
spacer()

0 commit comments

Comments
 (0)