Fix TypeError when child[‘@attributes’] is undefined.
Update deprecated attribute.nodeValue to attribute.value
Merge pull request #3 from cotycondry/master

Fix for undefined @attributes, update the deprecated nodeValue