Skip to content

Commit

Permalink
Fixed memory leak in View
Browse files Browse the repository at this point in the history
  • Loading branch information
staltz committed Jan 5, 2015
1 parent f9e733a commit ebc3c1e
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions dist/cycle.js
Original file line number Diff line number Diff line change
Expand Up @@ -17624,7 +17624,7 @@ function getCorrectedVtree$(view) {
replaceStreamNameWithStream(vtree, view);
return vtree;
})
.replay();
.replay(null, 1);
newVtree$.connect();
return newVtree$;
}
Expand All @@ -17640,7 +17640,6 @@ function overrideGet(view) {
} else {
var result = oldGet.call(this, streamName);
if (!result) {
console.log('there was no ' + streamName + ' in the view, in view.get');
view[streamName] = new Rx.Subject();
return view[streamName];
} else {
Expand Down
2 changes: 1 addition & 1 deletion dist/cycle.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/create-view.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ function getCorrectedVtree$(view) {
replaceStreamNameWithStream(vtree, view);
return vtree;
})
.replay();
.replay(null, 1);
newVtree$.connect();
return newVtree$;
}
Expand Down
2 changes: 1 addition & 1 deletion test/phantomjs/custom-elements.js
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ describe('Custom Elements', function () {
assert.strictEqual(myElement.textContent, '8')
assert.strictEqual(myElement.style.color, 'rgb(0, 255, 0)');
done();
}, 150);
}, 250);
});


Expand Down

0 comments on commit ebc3c1e

Please sign in to comment.