Don't execute hooks if ci was supposed to be skipped

And we should preserve the return value
This commit is contained in:
Lin Jen-Shin 2016-07-29 17:06:09 +08:00
parent b831ef716b
commit d41e83e91a
1 changed files with 3 additions and 2 deletions

View File

@ -237,8 +237,9 @@ module Ci
self.started_at = statuses.started_at self.started_at = statuses.started_at
self.finished_at = statuses.finished_at self.finished_at = statuses.finished_at
self.duration = statuses.latest.duration self.duration = statuses.latest.duration
save saved = save
execute_hooks execute_hooks if saved && !skip_ci?
saved
end end
def execute_hooks def execute_hooks