-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
22 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -877,6 +877,27 @@ Renderer.setMethod(function _prepareClone(wm, custom_method) { | |
|
||
}); | ||
|
||
/** | ||
* Handle an error | ||
* | ||
* @author Jelle De Loecker <[email protected]> | ||
* @since 2.3.16 | ||
* @version 2.3.16 | ||
* | ||
* @return {string} | ||
*/ | ||
Renderer.setMethod(function handleError(error) { | ||
|
||
if (!error) { | ||
error = new Error('Unknown error'); | ||
} | ||
|
||
let template_name = this.current_template?.name || this.errName; | ||
let line_nr = this.errLine; | ||
|
||
return this.hawkejs.handleError(this, template_name, line_nr, error); | ||
}); | ||
|
||
/** | ||
* Flag this renderer (and all its children) as finished | ||
* | ||
|