fix(api-builder/addJadeDataDocs): handle newlines better (#2296)

Closes #2294
This commit is contained in:
Peter Bacon Darwin 2016-09-09 10:16:54 +01:00 committed by Tobias Bosch
parent 672ba7f479
commit 2c9e78c500

View File

@ -95,7 +95,7 @@ module.exports = function addJadeDataDocsProcessor() {
}); });
// Remove line breaks, there should only be one tag // Remove line breaks, there should only be one tag
howToUse = howToUseArray[0].description.replace(/(\r\n|\n|\r)/gm,""); howToUse = howToUseArray[0].description.replace(/(\r\n|\n|\r)/gm," ");
} }
var whatItDoes = ''; var whatItDoes = '';
@ -105,7 +105,7 @@ module.exports = function addJadeDataDocsProcessor() {
}); });
// Remove line breaks, there should only be one tag // Remove line breaks, there should only be one tag
whatItDoes = whatItDoesArray[0].description.replace(/(\r\n|\n|\r)/gm,""); whatItDoes = whatItDoesArray[0].description.replace(/(\r\n|\n|\r)/gm," ");
} }
// SECURITY STATUS // SECURITY STATUS
@ -119,7 +119,7 @@ module.exports = function addJadeDataDocsProcessor() {
}); });
// Remove line breaks, there should only be one tag // Remove line breaks, there should only be one tag
security = securityArray[0].description.replace(/(\r\n|\n|\r)/gm,""); security = securityArray[0].description.replace(/(\r\n|\n|\r)/gm," ");
exportDoc.showSecurityNotes = true; exportDoc.showSecurityNotes = true;
} }