Skip to content

Instantly share code, notes, and snippets.

@aonawale
aonawale / push-deletion.js
Created July 21, 2018 21:02 — forked from runspired/push-deletion.js
Useful Ember Data helpers
/*
notifying the store that a record has been remotely deleted and should be fully removed.
*/
function pushDeletion(store, type, id) {
let record = store.peekRecord(type, id);
if (record !== null) {
let relationships = {};
let hasRelationships = false;