Skip to content

Commit

Permalink
feat: console.error on invalid edit
Browse files Browse the repository at this point in the history
  • Loading branch information
JakobVogelsang committed Dec 7, 2024
1 parent 7113299 commit 9663d03
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions handleEdit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -173,5 +173,7 @@ export function handleEdit(edit: EditV2): EditV2 {
if (isSetTextContent(edit)) return handleSetTextContent(edit);
if (isComplex(edit)) return edit.map((edit) => handleEdit(edit)).reverse();

console.error(`Invalid edit provided: ${edit}`);

return [];
}

0 comments on commit 9663d03

Please sign in to comment.