Sha256: a626b9a41cef444ea34eec6f8078697aface216e209ccfcd3251a588e17930cb
Contents?: true
Size: 487 Bytes
Versions: 4
Compression:
Stored size: 487 Bytes
Contents
Bookmark.without_auditing do [ { :name => "running", :query => "state = running" }, { :name => "failed", :query => "state = paused or result = error or result = warning" } ].each do |item| next if Bookmark.find_by_name(item[:name]) next if audit_modified? Bookmark, item[:name] b = Bookmark.create({:controller => "foreman_tasks_tasks", :public => true}.merge(item)) raise "Unable to create bookmark: #{format_errors b}" if b.nil? || b.errors.any? end end
Version data entries
4 entries across 4 versions & 1 rubygems