src/ConfigParser/ConfigParser.js
function findElementAttributeValue(attributeName, elems) {

    elems = Array.isArray(elems) ? elems : [ elems ];

    var value = elems.filter(function (elem) {
        return elem.attrib.name.toLowerCase() === attributeName.toLowerCase();
    }).map(function (filteredElems) {
        return filteredElems.attrib.value;
    }).pop();

    return value ? value : '';
}
function findElementAttributeValue(attributeName, elems) {

    elems = Array.isArray(elems) ? elems : [ elems ];

    var value = elems.filter(function (elem) {
        return elem.attrib.name.toLowerCase() === attributeName.toLowerCase();
    }).map(function (filteredElems) {
        return filteredElems.attrib.value;
    }).pop();

    return value ? value : '';
}
function findElementAttributeValue ( attributeName , elems ) { elems = Array . isArray ( elems ) ? elems : [ elems ] ; var value = elems . filter ( function ( elem ) { return elem . attrib . name . toLowerCase ( ) === attributeName . toLowerCase ( ) ; } ) . map ( function ( filteredElems ) { return filteredElems . attrib . value ; } ) . pop ( ) ; return value ? value : '' ; }
Finds the value of an element's attribute
@param  {String} attributeName Name of the attribute to search for
@param  {Array}  elems         An array of ElementTree nodes
@return {String}
Finds the value of an element s attribute