Skip to content

Commit

Permalink
fix(context_files): fix the format of the messages sent to the lsp
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcMcIntosh committed Jan 5, 2024
1 parent 01eeef0 commit 905a832
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/services/refact.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,7 @@ export function sendChat(
) {
const jsonMessages = messages.map(([role, textOrFile]) => {
const content =
typeof textOrFile === "string"
? textOrFile
: JSON.stringify([textOrFile]);
typeof textOrFile === "string" ? textOrFile : JSON.stringify(textOrFile);
return { role, content };
});

Expand Down

0 comments on commit 905a832

Please sign in to comment.