lib/cmsTxtToIntObj.js
function clean(cmsString) {
    if (cmsString.indexOf('\r\n') >= 0) {
        cmsString = cmsString.replace(/\r\n/g, '\n');
        cmsString = cmsString.replace(/\r/g, '\n');
    }
    cmsString = cmsString.replace(/\n{5,}/g, '\n\n\n\n'); //more than 5 line breaks breaks the parser
    return cmsString;
}
function clean(cmsString) {
    if (cmsString.indexOf('\r\n') >= 0) {
        cmsString = cmsString.replace(/\r\n/g, '\n');
        cmsString = cmsString.replace(/\r/g, '\n');
    }
    cmsString = cmsString.replace(/\n{5,}/g, '\n\n\n\n'); //more than 5 line breaks breaks the parser
    return cmsString;
}
function clean ( cmsString ) { if ( cmsString . indexOf ( '\r\n' ) >= 0 ) { cmsString = cmsString . replace ( / \r\n / g , '\n' ) ; cmsString = cmsString . replace ( / \r / g , '\n' ) ; } cmsString = cmsString . replace ( / \n{5,} / g , '\n\n\n\n' ) ; //more than 5 line breaks breaks the parser return cmsString ; }
main function that will be used to getIntObj
main function that will be used to getIntObj