git.asbjorn.biz
/
jquery.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Update Rakefile to remove module wrappers (feature parity with make and ant). Update...
[jquery.git]
/
src
/
data.js
diff --git
a/src/data.js
b/src/data.js
index
120fe71
..
4d1d1bd
100644
(file)
--- a/
src/data.js
+++ b/
src/data.js
@@
-10,7
+10,8
@@
jQuery.extend({
uuid: 0,
// Unique for each copy of jQuery on the page
uuid: 0,
// Unique for each copy of jQuery on the page
- expando: "jQuery" + jQuery.now(),
+ // Non-digits removed to match rinlinejQuery
+ expando: "jQuery" + ( jQuery.fn.jquery + Math.random() ).replace( /\D/g, "" ),
// The following elements throw uncatchable exceptions if you
// attempt to add expando properties to them.
// The following elements throw uncatchable exceptions if you
// attempt to add expando properties to them.
@@
-22,7
+23,11
@@
jQuery.extend({
},
hasData: function( elem ) {
},
hasData: function( elem ) {
- return !elem.nodeType || (elem[ jQuery.expando ] && !jQuery.isEmptyObject(jQuery.cache[ elem[jQuery.expando] ]));
+ if ( elem.nodeType ) {
+ elem = jQuery.cache[ elem[jQuery.expando] ];
+ }
+
+ return !!elem && !jQuery.isEmptyObject(elem);
},
data: function( elem, name, data ) {
},
data: function( elem, name, data ) {