Skip to content

Commit

Permalink
Update parser.js
Browse files Browse the repository at this point in the history
Restored parseUseDirectives functionality, maintaining getElementsByTagName and  changing logic of running trought the list.
  • Loading branch information
asturur committed Jul 20, 2014
1 parent 481b405 commit 85ba574
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -371,8 +371,8 @@
*/
function parseUseDirectives(doc) {
var nodelist = doc.getElementsByTagName('use');
for (var i = 0, len = nodelist.length; i < len; i++) {
var el = nodelist[i],
while (nodelist.length) {
var el = nodelist[0],
xlink = el.getAttribute('xlink:href').substr(1),
x = el.getAttribute('x') || 0,
y = el.getAttribute('y') || 0,
Expand Down

0 comments on commit 85ba574

Please sign in to comment.