Skip to content

Instantly share code, notes, and snippets.

@ppcano
Created September 14, 2012 09:35
Show Gist options
  • Select an option

  • Save ppcano/3721023 to your computer and use it in GitHub Desktop.

Select an option

Save ppcano/3721023 to your computer and use it in GitHub Desktop.
Ember-data cleanRecordCache
Yn.Store = DS.Store.extend({
revision: 4,
serverDomain: "",
adapter: Yn.DjangoTastypieAdapter.create({
}),
cleanRecordCache: function(type) {
var typeMaps = this.get('typeMaps');
var guidForType = Ember.guidFor(type);
typeMaps[guidForType] = {
idToCid: {},
clientIds: [],
cidToHash: {},
recordArrays: []
};
this.set('typeMaps', typeMaps);
}
});
@ppcano

ppcano commented Sep 14, 2012

Copy link
Copy Markdown
Author

what is necessary to unload a specific record?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment