Bug Tracker

Opened 9 years ago

Closed 9 years ago

#14684 closed bug (notabug)

Data creates new object

Reported by: [email protected] Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 2.0.2
Keywords: Cc:
Blocked by: Blocking:



var a={};
console.log(a==$(document).data()); // returns false, expected: true, BUG?!

var a={};
console.log(a==$(document).data('a')); // returns true, expected: true, OK

Change History (1)

comment:1 Changed 9 years ago by scottgonzalez

Resolution: notabug
Status: newclosed

There is no API for setting the entirety of the data. You're using an API for setting multiple individual properties, of which you're setting none.

Note: See TracTickets for help on using tickets.