prevent nonsensical IE error
This commit is contained in:
parent
e6d6db6123
commit
c57b0b4047
1 changed files with 5 additions and 2 deletions
|
|
@ -364,8 +364,11 @@ var m = (function app(window, undefined) {
|
|||
clear(cached.nodes, cached);
|
||||
nodes = [$document.createTextNode(data)]
|
||||
}
|
||||
try {parentElement.insertBefore(nodes[0], parentElement.childNodes[index] || null);} catch (e) {} //IE erroneously throws error when appending an empty text node after a null
|
||||
nodes[0].nodeValue = data
|
||||
try {
|
||||
parentElement.insertBefore(nodes[0], parentElement.childNodes[index] || null);
|
||||
nodes[0].nodeValue = data
|
||||
}
|
||||
catch (e) {} //IE erroneously throws error when appending an empty text node after a null
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue