app/controllers/categories_controller.rb
# Only allow a trusted parameter "white list" through.
Only allow a trusted parameter "white list" through.
Only allow a trusted parameter " white list " through .
def category_params
      params.require(:category).permit(:name)
    end
def category_params params . require ( :category ) . permit ( :name ) end
Only allow a trusted parameter "white list" through.
Only allow a trusted parameter " white list " through .
#params.fetch(:category, {})