getMetaAttributes: function() {
var toret = {};
this.getAttrs().forEach(function(attr) {
- if(isMetaAttribute(attr.name))
- meta[attr.name.substr(5)] = attr.value;
+ if(isMetaAttribute(attr.name)) {
+ toret[attr.name.substr(5)] = attr.value;
+ }
});
return toret;
},
getOtherAttributes: function() {
var toret = {};
this.getAttrs().forEach(function(attr) {
- if(attr.name != 'class' && !isMetaAttribute(attr.name))
+ if(attr.name !== 'class' && !isMetaAttribute(attr.name)) {
toret[attr.name] = attr.value;
+ }
});
return toret;
}
return {
WLXMLDocumentFromXML: function(xml) {
return new WLXMLDocument(xml);
- }
+ },
+
+ WLXMLElementNodeFromXML: function(xml) {
+ return this.WLXMLDocumentFromXML(xml).root;
+ }
};
});
\ No newline at end of file