Skip to content

Commit

Permalink
record-data support
Browse files Browse the repository at this point in the history
  • Loading branch information
runspired committed Aug 8, 2018
1 parent acbe677 commit 0a52592
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions addon/-record-data-private/system/store.js
Original file line number Diff line number Diff line change
Expand Up @@ -267,17 +267,6 @@ Store = Service.extend({
let tracked = this._trackedAsyncRequests;
let isSettled = tracked.length === 0;

if ((this.isDestroying || this.isDestroyed) && !isSettled) {
warn(
'Async Request leaks detected. Add a breakpoint here and set `store._generateStackTracesForTrackedRequests = true;`to inspect traces for leak origins:\n\t - ' +
tracked.map(o => o.label).join('\n\t - '),
false,
{
id: 'ds.async.leak.detected',
}
);
}

return shouldTrack !== true || isSettled;
};

Expand Down Expand Up @@ -3127,6 +3116,7 @@ Store = Service.extend({
this.unloadAll();

if (DEBUG) {
Ember.Test.unregisterWaiter(this.__asyncWaiter);
let shouldTrack = this._shouldTrackAsyncRequests;
let tracked = this._trackedAsyncRequests;
let isSettled = tracked.length === 0;
Expand All @@ -3148,7 +3138,6 @@ Store = Service.extend({
);
}
}
Ember.Test.unregisterWaiter(this.__asyncWaiter);
}
},

Expand Down

0 comments on commit 0a52592

Please sign in to comment.