app/controllers/reviews_controller.rb
# Nested resource which renders all the author reviews
Nested resource which renders all the author reviews
Nested resource which renders all the author reviews
def index
    author = Author.find(params[:author_id])
    @reviews = author.reviews
    render json: @reviews
  end
def index author = Author . find ( params [ :author_id ] ) @reviews = author . reviews render json : @reviews end
Nested resource which renders all the author reviews
Nested resource which renders all the author reviews