diff options
author | Shinya Maeda <shinya@gitlab.com> | 2017-09-04 16:46:37 +0300 |
---|---|---|
committer | Shinya Maeda <shinya@gitlab.com> | 2017-09-05 08:30:28 +0300 |
commit | 5d50cbfaab1d67ffaea6064aeac848f1fc1127a6 (patch) | |
tree | c3a4e42a6a21410845d76a295c91ce351bba4b71 /lib/api/runner.rb | |
parent | 69df47c7e43e1661faf97eb6d2b287a346215c31 (diff) |
Use unknown_failure for runner
Diffstat (limited to 'lib/api/runner.rb')
-rw-r--r-- | lib/api/runner.rb | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/lib/api/runner.rb b/lib/api/runner.rb index 44ca42fef68..76354fd8c98 100644 --- a/lib/api/runner.rb +++ b/lib/api/runner.rb @@ -129,11 +129,8 @@ module API when 'success' job.success when 'failed' - if params[:failure_reason] - job.drop(params[:failure_reason].to_sym) - else - job.drop(:job_failure) - end + failure_reason = params[:failure_reason] ? params[:failure_reason].to_sym : :unknown_failure + job.drop(failure_reason) end end |