Skip to content

Commit

Permalink
Merge pull request #226 from bitovi/ie8-list-setup-226
Browse files Browse the repository at this point in the history
IE8 error
  • Loading branch information
daffl committed Jan 23, 2013
2 parents d375409 + a61d47e commit 06163f6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion observe/observe.js
Expand Up @@ -1029,7 +1029,7 @@ steal('can/util','can/construct', function(can) {
this.length = 0;
can.cid(this, ".observe")
this._init = 1;
this.push.apply(this, instances || []);
this.push.apply(this, can.makeArray(instances || []));
this.bind('change'+this._cid,can.proxy(this._changes,this));
can.extend(this, options);
delete this._init;
Expand Down
7 changes: 7 additions & 0 deletions observe/observe_test.js
Expand Up @@ -591,4 +591,11 @@ test("replace with a deferred that resolves to an Observe.List", function(){
list.replace(def);
});

test("IE8 error on list setup with Observe.List (#226)", function() {
var list = new can.Observe.List(['first', 'second', 'third']),
otherList = new can.Observe.List(list);

deepEqual(list.attr(), otherList.attr(), 'Lists are the same');
});

})();

0 comments on commit 06163f6

Please sign in to comment.