From: Dave Methvin Date: Wed, 18 Sep 2013 03:29:02 +0000 (-0400) Subject: Fix #14290. Don't throw if text node is appended to table. Close gh-1371. X-Git-Tag: 2.1.0-beta1~1 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=ec3ac9a247ec3132dea3c30ca36cefc217e25441;p=jquery.git Fix #14290. Don't throw if text node is appended to table. Close gh-1371. --- diff --git a/src/manipulation.js b/src/manipulation.js index afaaa30ea..e27616fe3 100644 --- a/src/manipulation.js +++ b/src/manipulation.js @@ -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") ) :