Skip to content

Instantly share code, notes, and snippets.

@raldred
Created October 3, 2009 10:23
Show Gist options
  • Save raldred/200553 to your computer and use it in GitHub Desktop.
Save raldred/200553 to your computer and use it in GitHub Desktop.
def update_attributes_with_seed_products(params)
return false if params.empty?
if params[:seed_all_products] || params[:seed_selected_products]
return seed_products(params)
end
update_attributes_without_seed_products(params)
end
def update_with_params(params)
return false if params.empty?
if params[:seed_all_products] || params[:seed_selected_products]
return seed_products(params)
end
update_attributes(params)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment