Commit f593abbc authored by Lin Jen-Shin's avatar Lin Jen-Shin

There's not always a pipeline

parent 590d61a2
......@@ -12,7 +12,7 @@ module Ci
pipelines.latest
end.first
image_name = image_for_status(latest_pipeline.status)
image_name = image_for_status(latest_pipeline.try(:status))
image_path = Rails.root.join('public/ci', image_name)
OpenStruct.new(path: image_path, name: image_name)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment