diff options
author | John Resig <jeresig@gmail.com> | 2009-02-18 02:40:55 +0000 |
---|---|---|
committer | John Resig <jeresig@gmail.com> | 2009-02-18 02:40:55 +0000 |
commit | 3e46bce751f062775be95a6bef3cf53096a3ed21 (patch) | |
tree | e69e4c94afd895d4f7efc42c828f2915754989ed | |
parent | 1ac087f6f90eb41fe79d46b7e1f09cc7e2125670 (diff) | |
download | jquery-3e46bce751f062775be95a6bef3cf53096a3ed21.tar.gz jquery-3e46bce751f062775be95a6bef3cf53096a3ed21.zip |
A speedup for .remove() (which also speeds up .html()). Fixes #4178.
-rw-r--r-- | src/core.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core.js b/src/core.js index d78ec7e41..c7d10f3c8 100644 --- a/src/core.js +++ b/src/core.js @@ -1234,7 +1234,7 @@ jQuery.each({ empty: function() { // Remove element nodes and prevent memory leaks - jQuery( ">*", this ).remove(); + jQuery(this).children().remove(); // Remove any remaining nodes while ( this.firstChild ) |