Fixed error in Safari, where .children really is only defined on HTML elements and is not available for SVG.
Merge pull request #1 from robbert/master

Safari only has .children defined on HTML elements