diff options
Diffstat (limited to 'app/models/commit.rb')
-rw-r--r-- | app/models/commit.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/models/commit.rb b/app/models/commit.rb index f698e39..0e10033 100644 --- a/app/models/commit.rb +++ b/app/models/commit.rb @@ -34,6 +34,12 @@ class Commit < ActiveRecord::Base builds.last end + def retry + builds_without_retry.each do |build| + Build.retry(build) + end + end + def valid_commit_sha if self.sha == Git::BLANK_SHA self.errors.add(:sha, " cant be 00000000 (branch removal)") |