diff --git a/Gemfile.lock b/Gemfile.lock index 180639ce..4dcc389b 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -50,7 +50,7 @@ GIT GIT remote: git://github.com/travis-ci/travis-core.git - revision: f39caf6da61b8a988ccf3e2d3e0272df427f59a3 + revision: 3adf0cd02db39c78245d5987f2efe34d336b2e70 branch: rkh-branches specs: travis-core (0.0.1) diff --git a/lib/travis/api/v3/models/branch.rb b/lib/travis/api/v3/models/branch.rb index 578edaed..faa7259e 100644 --- a/lib/travis/api/v3/models/branch.rb +++ b/lib/travis/api/v3/models/branch.rb @@ -2,7 +2,7 @@ module Travis::API::V3 class Models::Branch < Model belongs_to :repository belongs_to :last_build, class_name: 'Travis::API::V3::Models::Build'.freeze - has_many :builds, foreign_key: [:repository_id, :branch], primary_key: [:repository_id, :name], order: 'id DESC'.freeze + has_many :builds, foreign_key: [:repository_id, :branch], primary_key: [:repository_id, :name], order: 'id DESC'.freeze, conditions: { event_type: 'push' } has_many :commits, foreign_key: [:repository_id, :branch], primary_key: [:repository_id, :name], order: 'id DESC'.freeze end end