summaryrefslogtreecommitdiff
path: root/app/node_modules/oktemplate/index.js
diff options
context:
space:
mode:
authorSean Fridman <fridman@mail.sfsu.edu>2015-04-07 22:19:24 -0400
committerSean Fridman <fridman@mail.sfsu.edu>2015-04-07 22:19:24 -0400
commitc4a05d608d59a178dbdb7494fedb7a63cf55f96f (patch)
treeaeca511b7d06c1b09eb89110fd475a053b16bb15 /app/node_modules/oktemplate/index.js
parent8896617d1b5db8f4c58c08a4fb7361ce9e55281a (diff)
Add error catch template stringify filter
Diffstat (limited to 'app/node_modules/oktemplate/index.js')
-rw-r--r--app/node_modules/oktemplate/index.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/app/node_modules/oktemplate/index.js b/app/node_modules/oktemplate/index.js
index 09a78bf..65f8c18 100644
--- a/app/node_modules/oktemplate/index.js
+++ b/app/node_modules/oktemplate/index.js
@@ -15,7 +15,11 @@ liquid.registerFilters({
* Useful for quick debugging of template data.
*/
stringify: function(obj) {
- return '<pre>' + stringify(obj) + '</pre>';
+ try {
+ return '<pre>' + stringify(obj) + '</pre>';
+ } catch (e) {
+ return '';
+ }
}
});