0 / 60 seg.

Given this controller code, which choice describes the expected behavior if parameters are submitted to the update action that includes values for the product's name, style, color, and price?

class ProductController < ActionController::Base
  def update
    @product = Product.find(params[:id])
    if @product.update_attributes(product_params)
      redirect_to(product_path(@product))
    else
      render('edit')
    end
  end
  private
  def product_params
    params.require(:product).permit(:name, :style, :color)
  end
end