aboutsummaryrefslogtreecommitdiffstats
path: root/src/manipulation.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/manipulation.js')
-rw-r--r--src/manipulation.js10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/manipulation.js b/src/manipulation.js
index 75c6be7b4..3193ad7af 100644
--- a/src/manipulation.js
+++ b/src/manipulation.js
@@ -243,15 +243,9 @@ jQuery.fn.extend({
var next = this.nextSibling,
parent = this.parentNode;
- if ( parent && this.nodeType === 1 || this.nodeType === 11 ) {
-
+ if ( parent ) {
jQuery( this ).remove();
-
- if ( next ) {
- next.parentNode.insertBefore( elem, next );
- } else {
- parent.appendChild( elem );
- }
+ parent.insertBefore( elem, next );
}
});
},