Commit 75a0b4a7 authored by Dave Methvin's avatar Dave Methvin

Fix #14290. Don't throw if text node is appended to table. Close gh-1371.

(cherry picked from commit ec3ac9a2)
parent 60004e68
...@@ -105,7 +105,7 @@ function fixDefaultChecked( elem ) { ...@@ -105,7 +105,7 @@ function fixDefaultChecked( elem ) {
// Manipulating tables requires a tbody // Manipulating tables requires a tbody
function manipulationTarget( elem, content ) { function manipulationTarget( elem, content ) {
return jQuery.nodeName( elem, "table" ) && 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.getElementsByTagName("tbody")[0] ||
elem.appendChild( elem.ownerDocument.createElement("tbody") ) : elem.appendChild( elem.ownerDocument.createElement("tbody") ) :
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment