splice
in DefineListt removing undefined
values in source array
#471
Labels
splice
in DefineListt removing undefined
values in source array
#471
How often can you reproduce it?
Description:
If the source array for a new
DefineList
contains only values ofundefined
at each index, it passes theallSame
test here when calling splice:can-define/list/list.js
Lines 294 to 297 in ea827f8
as it thinks nothing will change, and ends up returning a
DefineList
of length 0. As long as at least one element in the source array is notundefined
it works as expected.See this codepen example:
https://codepen.io/mikemitchel/pen/eYOMwmE
Expected results:
I expected in the first example of the codepen to have a
DefineList
of length 2, with the value at each index beingundefined
.Environment:
The text was updated successfully, but these errors were encountered: