Skip to content

Commit

Permalink
feat(listLineOutputParser): handle unclosed tags
Browse files Browse the repository at this point in the history
  • Loading branch information
ItzCrazyKns committed Oct 30, 2024
1 parent 65d057a commit 012dfa5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/outputParsers/listLineOutputParser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class LineListOutputParser extends BaseOutputParser<string[]> {
const startKeyIndex = text.indexOf(`<${this.key}>`);
const endKeyIndex = text.indexOf(`</${this.key}>`);

if (startKeyIndex === -1 || endKeyIndex === -1) {
if (startKeyIndex === -1 && endKeyIndex === -1) {
return [];
}

Expand Down

0 comments on commit 012dfa5

Please sign in to comment.