From 486f7c904e08f1a524335afe44372fc056f2a0f6 Mon Sep 17 00:00:00 2001 From: Jordan Hollinger Date: Mon, 11 Jun 2012 23:33:17 -0400 Subject: [PATCH] Bugfix to setHTML - it was ignoring the last letter of each line. fixes issue #768 --- src/node/utils/ImportHtml.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/node/utils/ImportHtml.js b/src/node/utils/ImportHtml.js index 5c6bb634e..7c638fb8c 100644 --- a/src/node/utils/ImportHtml.js +++ b/src/node/utils/ImportHtml.js @@ -20,7 +20,6 @@ var log4js = require('log4js'); var Changeset = require("ep_etherpad-lite/static/js/Changeset"); var contentcollector = require("ep_etherpad-lite/static/js/contentcollector"); -var map = require("ep_etherpad-lite/static/js/ace2_common").map; function setPadHTML(pad, html, callback) { @@ -60,7 +59,7 @@ function setPadHTML(pad, html, callback) var attribsIter = Changeset.opIterator(attribs); var textIndex = 0; var newTextStart = 0; - var newTextEnd = newText.length - 1; + var newTextEnd = newText.length; while (attribsIter.hasNext()) { var op = attribsIter.next();