Skip to content

Commit

Permalink
ensure there is an active run loop
Browse files Browse the repository at this point in the history
  • Loading branch information
runspired committed Dec 21, 2016
1 parent 7efa6a1 commit bf25fe6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
4 changes: 3 additions & 1 deletion addon/-private/system/store.js
Original file line number Diff line number Diff line change
Expand Up @@ -2654,7 +2654,9 @@ Store = Service.extend({
return;
}

this._backburner.schedule('syncRelationships', this, this._flushUpdatedRelationships);
this._backburner.join(() => {
this._backburner.schedule('syncRelationships', this, this._flushUpdatedRelationships);
});
},

_flushUpdatedRelationships() {
Expand Down
4 changes: 4 additions & 0 deletions tests/dummy/app/routes/query/route.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ export default Route.extend({
let modelName = params.modelName;
delete params.modelName;

// Once heimdall 0.4.x is released we can uncomment this
// to have nice timeline and trace events integration
// heimdall.enableTimelineFeatures();

let token = heimdall.start('ember-data');
return this.get('store').query(modelName, params)
.then((records) => {
Expand Down

0 comments on commit bf25fe6

Please sign in to comment.