Merge pull request #895 from isiahmeadows/next
Fix issue with a placeholder
This commit is contained in:
commit
2b688a3334
1 changed files with 1 additions and 2 deletions
|
|
@ -1245,13 +1245,12 @@
|
|||
}
|
||||
})()
|
||||
|
||||
var placeholder = $document.createElement("span")
|
||||
|
||||
function injectHTML(parent, index, data) {
|
||||
var nextSibling = parent.childNodes[index]
|
||||
|
||||
if (nextSibling) {
|
||||
if (nextSibling.nodeType !== 1) {
|
||||
var placeholder = $document.createElement("span")
|
||||
parent.insertBefore(placeholder, nextSibling || null)
|
||||
placeholder.insertAdjacentHTML("beforebegin", data)
|
||||
parent.removeChild(placeholder)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue