From 8281d382e4a6b8dda18b1b758f0391a028961b14 Mon Sep 17 00:00:00 2001 From: John Crepezzi Date: Wed, 23 Nov 2011 16:58:56 -0500 Subject: [PATCH] on highlight error, return data --- static/application.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/static/application.js b/static/application.js index 2f4f86d..9140474 100644 --- a/static/application.js +++ b/static/application.js @@ -17,7 +17,7 @@ haste_document.prototype.load = function(key, callback, lang) { try { var high = lang ? hljs.highlight(lang, res.data) : hljs.highlightAuto(res.data); } catch(err) { - high = hljs.highlightAuto(res.data); + high = { value: res.data, language: null }; } callback({ value: high.value,