Method: Crowdblog::PostsController#index

Defined in:
app/controllers/crowdblog/posts_controller.rb

#indexObject



6
7
8
9
10
11
12
# File 'app/controllers/crowdblog/posts_controller.rb', line 6

def index
  @posts = Post.scoped_for(current_user).all_posts_json
  respond_to do |format|
    format.json { render json: @posts }
    format.html
  end
end