change logic of displaying noPR builds message

This commit is contained in:
Lisa Passing 2015-07-29 12:13:31 +02:00
parent 72b214e5b8
commit d15d35a9ff

View File

@ -22,7 +22,9 @@ Controller = Ember.ArrayController.extend
).property('tab', 'lastObject.number')
displayPullRequests: (->
if @get('tab') == 'pull_requests'
if Ember.isEmpty(@get('repo.builds.content'))
return false # if there is no build there is no PR
else if Ember.isEmpty(@get('repo.pullRequests.content'))
return true
else
return false