diff options
author | Douwe Maan <douwe@gitlab.com> | 2015-10-15 11:26:58 +0200 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2015-10-15 11:26:58 +0200 |
commit | 95f0440a7823a927ebba1557b091c12255e49ac4 (patch) | |
tree | fa6d130f2baff18e7a70d74dafe79e20da35babe /app/models/commit.rb | |
parent | 4a5b77188ec7525d1c3a1ee925c8791f841b040c (diff) | |
parent | 123669a55107514798ba531ba3a744b3ec8503ee (diff) | |
download | gitlab-ce-95f0440a7823a927ebba1557b091c12255e49ac4.tar.gz |
Merge branch 'master' into rs-redactor-filter
Diffstat (limited to 'app/models/commit.rb')
-rw-r--r-- | app/models/commit.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/app/models/commit.rb b/app/models/commit.rb index 95ac7156bed..23b5e38336c 100644 --- a/app/models/commit.rb +++ b/app/models/commit.rb @@ -184,4 +184,12 @@ class Commit def parents @parents ||= Commit.decorate(super, project) end + + def ci_commit + project.ci_commit(sha) + end + + def status + ci_commit.try(:status) || :not_found + end end |