Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge service template options on update #14314

Merged
merged 1 commit into from
Mar 15, 2017
Merged

Merge service template options on update #14314

merged 1 commit into from
Mar 15, 2017

Conversation

jntullo
Copy link

@jntullo jntullo commented Mar 13, 2017

As @bzwei pointed out, we should not assume that :config_info is the only key within options, and therefore the options should be merged.

@miq-bot add_label services
@miq-bot assign @gmcculloug

@@ -458,8 +458,8 @@ def resource_action_list
]
end

def update_from_options(options)
update_attributes!(options.except(:config_info).merge(:options => { :config_info => options[:config_info] }))
def update_from_options(params)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will this help a little bit of readability?

  options[:config_info] = params[:config_info]
  update_attributes!(params.except(:config_info))

@miq-bot
Copy link
Member

miq-bot commented Mar 14, 2017

Checked commit jntullo@bfeda5d with ruby 2.2.6, rubocop 0.47.1, and haml-lint 0.20.0
2 files checked, 0 offenses detected
Everything looks good. 🏆

@gmcculloug gmcculloug merged commit 95952ef into ManageIQ:master Mar 15, 2017
@gmcculloug gmcculloug added this to the Sprint 57 Ending Mar 27, 2017 milestone Mar 15, 2017
@gmcculloug gmcculloug added the bug label Mar 28, 2017
@jntullo jntullo deleted the fix/update_service_options branch November 28, 2017 19:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants