From 3bd189ed4cdfd6c8c0e18bf46234b61bff0e410f Mon Sep 17 00:00:00 2001 From: Vladimir Agafonkin Date: Tue, 30 Oct 2012 23:38:41 +0200 Subject: [PATCH] disregard line endings when comparing size --- build/build.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/build.js b/build/build.js index 355e740f..a4da18ae 100644 --- a/build/build.js +++ b/build/build.js @@ -74,6 +74,6 @@ exports.getSizeDelta = function (newContent, oldContent) { if (!oldContent) { return 'new'; } - var delta = newContent.length - oldContent.length; + var delta = newContent.replace(/\r\n?/g, '\n').length - oldContent.replace(/\r\n?/g, '\n').length; return (delta >= 0 ? '+' : '') + delta; }; \ No newline at end of file