Skip to content

Commit

Permalink
Add an error message
Browse files Browse the repository at this point in the history
  • Loading branch information
gitKrystan committed Dec 29, 2023
1 parent b4091b9 commit 0a5c894
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/parse/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,9 @@ function convertAst(ast: Node, rawTemplates: RawGlimmerTemplate[]): void {
if (templateIndex > -1) {
const rawTemplate = unprocessedTemplates.splice(templateIndex, 1)[0];
if (!rawTemplate) {
return null;
throw new Error(
'expected raw template because splice index came from findIndex',
);
}
convertNode(node, rawTemplate);
} else {
Expand Down

0 comments on commit 0a5c894

Please sign in to comment.