Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorKamil Trzciński <ayufan@ayufan.eu>2017-04-24 18:17:02 +0300
committerKamil Trzciński <ayufan@ayufan.eu>2017-04-24 18:17:02 +0300
commite2ff940685784760534294d7af658ff5d88103d3 (patch)
tree65c634da1e7fbcf5c3d988f4b875759f5778b8e9 /app
parent0affdb85b1c84d2664da634b5dea86c1be5e8c6a (diff)
parent103684b779d64d8d3e8aecb22314eec460858847 (diff)
Merge branch 'fix/gb/fix-blocked-pipeline-duration' into 'master'
Fix missing duration for blocked pipelines Closes #31264 See merge request !10856
Diffstat (limited to 'app')
-rw-r--r--app/models/ci/pipeline.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/ci/pipeline.rb b/app/models/ci/pipeline.rb
index 445247f1b41..75a8ab2f5cd 100644
--- a/app/models/ci/pipeline.rb
+++ b/app/models/ci/pipeline.rb
@@ -75,6 +75,10 @@ module Ci
pipeline.update_duration
end
+ before_transition any => [:manual] do |pipeline|
+ pipeline.update_duration
+ end
+
before_transition canceled: any - [:canceled] do |pipeline|
pipeline.auto_canceled_by = nil
end