When observing all builds don't request them
We use `allBuilds` to observe new incoming builds, so we can put new builds into the lists (for example when build is started). We use it for observing purposes only, so we actually don't need to get builds from the server, we can just register record array and use it later on.
This commit is contained in:
parent
766f4e8907
commit
d18cffd1a7
|
@ -22,7 +22,9 @@ require 'travis/model'
|
|||
).property('lastBuildId', 'lastBuildNumber')
|
||||
|
||||
allBuilds: (->
|
||||
Travis.Build.find()
|
||||
recordArray = DS.RecordArray.create({ type: Travis.Build, content: Ember.A([]), store: Travis.store, isLoaded: true })
|
||||
Travis.store.registerRecordArray(recordArray, Travis.Build)
|
||||
recordArray
|
||||
).property()
|
||||
|
||||
builds: (->
|
||||
|
|
Loading…
Reference in New Issue
Block a user