diff --git a/libs/util.js b/libs/util.js index 6f54cdd..6ac2282 100644 --- a/libs/util.js +++ b/libs/util.js @@ -59,9 +59,9 @@ exports.escape = function(html){ text += '~0'; - return text.replace(codeBlock, function (code) { + return text.replace(codeBlock, function (whole, code, nextChar) { blocks.push(code); - return '\n\tblock'; + return '\n\tblock' + nextChar; }) .replace(/&(?!\w+;)/g, '&') .replace(/\n\t<>\n<>'); + }); }); -}); \ No newline at end of file +});