mmpestorich/data — pull request #1 by mmpestorich (2013-09-16 19:33:17+00:00)
Title: Async BelongsTo should return a DS.PromiseObject

1) Currenty while traversing aync relationships:
```js
post.get('author') // this hasMany returns an Ember.RSVP.Promise
post.get('comments') // this belongsTo returns a DS.PromiseArray
```

Currently, an asyncBelongsTo relationship returns a regular Promise. I believe that they should be returning a DS.PromiseObject instead so that the returned value may serve as a proxy for the related object. This pull request changes the behavoir of asyncBelongsTo's so that a DS.PromiseObject is returned from a belongsTo instead of a regular Promise.

2) Currently, for various find requests:
```js
store.find('post', 1) // returns a DS.PromiseObject
store.findAll('post') // returns a DS.PromiseArray
store.findMany('post', [1,2,3]) // returns a DS.ManyArray
store.findQuery('post', { ... }) // returns a DS.PromiseArray
```

All find requests except findMany, currently return a thenable proxy. Is there any reason findMany can't also return a DS.PromiseArray that wraps the DS.ManyArray? This pull request does not address this but I thought it related to my first comment above, so I wanted some feedback... I think it could be easily incorporated into this pull request.