Ticket #5357 (closed defect: fixed)

Opened 12 months ago

Last modified 11 months ago

ItemFileWriteStore does not revert properly

Reported by: guest Owned by: jaredj
Priority: normal Milestone: 1.0.2
Component: Data Version: 1.0
Severity: major Keywords: ItemFileWriteStore revert
Cc:

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

dojo.data.ItemFileWriteStore_20071213.patch (2.0 kB) - added by jaredj 12 months ago.
Patch for this + UT.

Change History

Changed 12 months ago by jaredj

Patch for this + UT.

Changed 12 months ago by jaredj

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

Changed 12 months ago by jaredj

  • status changed from new to closed
  • resolution set to fixed

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

Changed 12 months ago by peller

  • milestone set to 1.0.3

Changed 11 months ago by peller

  • milestone changed from 1.0.3 to 1.0.2
Note: See TracTickets for help on using tickets.