Skip to content

Commit

Permalink
Merge pull request ManageIQ#15051 from jntullo/refactoring/rubocop_fixes
Browse files Browse the repository at this point in the history
Rubocop fixes in renderer
  • Loading branch information
abellotti authored May 11, 2017
2 parents 2420c03 + d3fbab4 commit 45e30d2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/controllers/api/base_controller/renderer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -285,14 +285,14 @@ def attr_split(attr)
def expand_actions(resource, json, type, opts)
return unless render_actions(resource)

href = json.attributes!["href"]
href = json.attributes!["href"]
cspec = collection_config[type]
aspecs = gen_action_spec_for_resources(cspec, opts[:is_subcollection], href, resource) if cspec
add_actions(json, aspecs, type)
end

def add_actions(json, aspecs, type)
if aspecs && aspecs.size > 0
if aspecs && aspecs.any?
json.actions do |js|
aspecs.each { |action_spec| add_child js, normalize_hash(type, action_spec) }
end
Expand Down

0 comments on commit 45e30d2

Please sign in to comment.