Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#13206 closed defect (fixed)

[patch][ccla] does not send correct put notification when the put object ID is 0

Reported by: cjolif Owned by: Kris Zyp
Priority: high Milestone: 1.7
Component: Data Version: 1.7.0b1
Keywords: Cc: Kris Zyp
Blocked By: Blocking:


See attached test case. When the id property of a data item is 0, the notification it has been modified is not correctly sent by Observable. More particularly the previousIndex attribute is set to -1 instead of the actual index of the element.

This comes from a test in Observable that test id existence this way:


while it should be:

if(existingId != undefined){

I have attached a patch that does this.

Attachments (2) (589 bytes) - added by cjolif 11 years ago.
PutFirstItemTest.js (1.1 KB) - added by cjolif 11 years ago.
test case

Download all attachments as: .zip

Change History (5)

Changed 11 years ago by cjolif


Changed 11 years ago by cjolif

Attachment: PutFirstItemTest.js added

test case

comment:1 Changed 11 years ago by Jared Jurkiewicz

Owner: changed from Jared Jurkiewicz to Kris Zyp

comment:2 Changed 11 years ago by Kris Zyp

Resolution: fixed
Status: newclosed

(In [25509]) Fixes handling of falsy ids, fixes #13206 !strict

comment:3 Changed 11 years ago by bill

Milestone: tbd1.7
Note: See TracTickets for help on using tickets.