1
0
Fork 0
mirror of synced 2024-10-05 04:25:21 +13:00

Include syntax errors in processJS

This commit is contained in:
Sam Rose 2024-10-04 10:32:33 +01:00
parent 831c81a99c
commit 28e6a03929
No known key found for this signature in database

View file

@ -126,7 +126,10 @@ export function processJS(handlebars: string, context: any) {
throw error
}
// If all else fails, generic error message.
if (error.name === "SyntaxError") {
return error.toString()
}
return "Error while executing JS"
}
}