diff --git a/src/node/handler/ImportHandler.js b/src/node/handler/ImportHandler.js index f58076bb..467def3b 100644 --- a/src/node/handler/ImportHandler.js +++ b/src/node/handler/ImportHandler.js @@ -114,7 +114,10 @@ exports.doImport = function(req, res, padId) //convert file to html function(callback) { if(!importHandledByPlugin){ - if (abiword) { + var fileEnding = path.extname(srcFile).toLowerCase(); + var fileIsHTML = (fileEnding === ".html" || fileEnding === ".htm"); + if (abiword && !fileIsHTML) { + console.warn("Using abiword"); abiword.convertFile(srcFile, destFile, "htm", function(err) { //catch convert errors if(err) {