Method: CommentsController#index
- Defined in:
- app/controllers/comments_controller.rb
#index ⇒ Object
38 39 40 41 42 43 44 45 46 |
# File 'app/controllers/comments_controller.rb', line 38 def index @post = Post.find(params[:post_id]) @comments = @post.comments respond_to do |format| format.html { redirect_to post_path(@post, :anchor => 'comments') } format.atom {} format.js { render @comments } end end |