]> source.dussan.org Git - jquery.git/commitdiff
Fix #14290. Don't throw if text node is appended to table. Close gh-1371.
authorDave Methvin <dave.methvin@gmail.com>
Wed, 18 Sep 2013 03:29:02 +0000 (23:29 -0400)
committerDave Methvin <dave.methvin@gmail.com>
Thu, 19 Sep 2013 14:24:22 +0000 (10:24 -0400)
src/manipulation.js

index afaaa30ea4c7045021c7646e381665515992732d..e27616fe3311c77ec03cb9534eb7d1f5637468b8 100644 (file)
@@ -52,7 +52,7 @@ require( "./event" );
 // Manipulating tables requires a tbody
 function manipulationTarget( elem, content ) {
        return jQuery.nodeName( elem, "table" ) &&
-               jQuery.nodeName( content.nodeType === 1 ? content : content.firstChild, "tr" ) ?
+               jQuery.nodeName( content.nodeType !== 11 ? content : content.firstChild, "tr" ) ?
 
                elem.getElementsByTagName("tbody")[0] ||
                        elem.appendChild( elem.ownerDocument.createElement("tbody") ) :