Merge pull request #2149 from ether/dont-use-abiword-for-html
abiword shouldnt be used for HTML native documents
This commit is contained in:
commit
cd294c608b
|
@ -114,7 +114,9 @@ exports.doImport = function(req, res, padId)
|
||||||
//convert file to html
|
//convert file to html
|
||||||
function(callback) {
|
function(callback) {
|
||||||
if(!importHandledByPlugin){
|
if(!importHandledByPlugin){
|
||||||
if (abiword) {
|
var fileEnding = path.extname(srcFile).toLowerCase();
|
||||||
|
var fileIsHTML = (fileEnding === ".html" || fileEnding === ".htm");
|
||||||
|
if (abiword && !fileIsHTML) {
|
||||||
abiword.convertFile(srcFile, destFile, "htm", function(err) {
|
abiword.convertFile(srcFile, destFile, "htm", function(err) {
|
||||||
//catch convert errors
|
//catch convert errors
|
||||||
if(err) {
|
if(err) {
|
||||||
|
|
Loading…
Reference in New Issue