I have a feed object which hasMany feedTracks, each feedTrack has a track associated with it.
These relationships work successfully, but when I try to use a computed property, something breaks.
on the feed model i have:
secondFeedTrack: computed('feedTracks.[]', function() {
return this.get('feedTracks').then((feedTracks) => {
return feedTracks.objectAt(1);
});
})
when i do I get:
Object { _id: 136, _label: undefined, _state: undefined, _result: undefined, _subscribers: Array[0] }
which isn't nothing, but it doesn't look right.
when i do i get undefined.
What am i doing wrong to not properly get a feedTrack from the computed property?
Aucun commentaire:
Enregistrer un commentaire