diff --git a/actionpack/lib/action_controller/api.rb b/actionpack/lib/action_controller/api.rb index cb819067da6789e405e2d170e21dbb73728385b8..9dc96bd3e693e4f56ed4abf3213f60ebcc8ae0f0 100644 --- a/actionpack/lib/action_controller/api.rb +++ b/actionpack/lib/action_controller/api.rb @@ -71,11 +71,13 @@ module ActionController # end # # class PostsController < ApplicationController - # respond_to :json, :xml - # # def index # @posts = Post.all - # respond_with @posts + # + # respond_to do |format| + # format.json { render json: @posts } + # format.xml { render xml: @posts } + # end # end # end #