Skip to content

Instantly share code, notes, and snippets.

@j-mcnally
Forked from joachimhs/gist:5760807
Created June 11, 2013 21:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save j-mcnally/5760995 to your computer and use it in GitHub Desktop.
Save j-mcnally/5760995 to your computer and use it in GitHub Desktop.
contentArrayContains: function(id, type) {
var contains = null;
Ember.get(type, 'collection').forEach(function(item) {
if (item.get('id') === id) {
contains = item;
}
});
return contains;
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment