git.asbjorn.biz
/
jquery.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a4ec609
)
Fixed issue with comment text being included in .text() results.
author
John Resig
<jeresig@gmail.com>
Thu, 31 Aug 2006 04:19:59 +0000
(
04:19
+0000)
committer
John Resig
<jeresig@gmail.com>
Thu, 31 Aug 2006 04:19:59 +0000
(
04:19
+0000)
src/jquery/jquery.js
patch
|
blob
|
history
diff --git
a/src/jquery/jquery.js
b/src/jquery/jquery.js
index
c8605d9
..
fc3d551
100644
(file)
--- a/
src/jquery/jquery.js
+++ b/
src/jquery/jquery.js
@@
-378,8
+378,9
@@
jQuery.fn = jQuery.prototype = {
for ( var j = 0; j < e.length; j++ ) {
var r = e[j].childNodes;
for ( var i = 0; i < r.length; i++ )
- t += r[i].nodeType != 1 ?
- r[i].nodeValue : jQuery.fn.text([ r[i] ]);
+ if ( r[i].nodeType != 8 )
+ t += r[i].nodeType != 1 ?
+ r[i].nodeValue : jQuery.fn.text([ r[i] ]);
}
return t;
},