From 8320730ea9660d0af88374de9e3cfe53e80f275c Mon Sep 17 00:00:00 2001 From: Michael Jackson Date: Mon, 23 Jan 2012 15:04:51 -0800 Subject: [PATCH] Omit carriage returns Fixes #156 --- mustache.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mustache.js b/mustache.js index 68a0ff2..b71f325 100644 --- a/mustache.js +++ b/mustache.js @@ -404,6 +404,9 @@ var Mustache = (typeof module !== "undefined" && module.exports) || {}; nonSpace = true; code.push("\\" + c); break; + case "\r": + // Ignore carriage returns. + break; case "\n": spaces.push(code.length); code.push("\\n");