Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#5357 closed defect (fixed)

ItemFileWriteStore does not revert properly

Reported by: guest Owned by: Jared Jurkiewicz
Priority: high Milestone: 1.0.2
Component: Data Version: 1.0
Keywords: ItemFileWriteStore revert Cc:
Blocked By: Blocking:

Description

When items are added there is a

newItem[this._itemNumPropName]=this._arrayOfAllItems.length and then this_arrayOfAllItems.push(newItem).

On the revert it does

this._arrayOfAllItems[newItem._itemNumPropName]=null.

It should be this._arrayOfAllItems[newItem[this._itemNumPropName]].

JavaScript? in its wisdom is failing silently here since newItem has no _itemNumPropName. It is also clear that the functionality was never tested when the method was changed for version 1.0. Include a test case with the fix!

Attachments (1)

dojo.data.ItemFileWriteStore_20071213.patch (2.0 KB) - added by Jared Jurkiewicz 11 years ago.
Patch for this + UT.

Download all attachments as: .zip

Change History (5)

Changed 11 years ago by Jared Jurkiewicz

Patch for this + UT.

comment:1 Changed 11 years ago by Jared Jurkiewicz

Tested on: FireFox? 2.0.0.11 IE 6 Safari B3 Opera 9.2 SeaMonkey? 1.1.2

comment:2 Changed 11 years ago by Jared Jurkiewicz

Resolution: fixed
Status: newclosed

(In [11812]) Minor defect fix + UT. fixes #5357

comment:3 Changed 11 years ago by Adam Peller

Milestone: 1.0.3

comment:4 Changed 11 years ago by Adam Peller

Milestone: 1.0.31.0.2
Note: See TracTickets for help on using tickets.