Skip to content

Commit

Permalink
Merge pull request #16860 from pieter-v/proxy-leak
Browse files Browse the repository at this point in the history
[BUGFIX release] Clear chains in ProxyMixin when destroyed
  • Loading branch information
rwjblue committed Sep 5, 2018
2 parents 8d059ab + aca371c commit fa43958
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/@ember/-internals/runtime/lib/mixins/-proxy.js
Expand Up @@ -61,6 +61,11 @@ export default Mixin.create({
m.writableTag(() => combine([DirtyableTag.create(), UpdatableTag.create(CONSTANT_TAG)]));
},

willDestroy() {
this.set('content', null);
this._super(...arguments);
},

isTruthy: computed('content', function() {
return !!get(this, 'content');
}),
Expand Down

0 comments on commit fa43958

Please sign in to comment.