I'm searching a reason why `rake routes` doesn't match the `index` path of my nested resource.

Here is my code:

```
namespace :api do
  resources :photos do
    resource :comments
  end
end

```

Here is the result of the command: `rake routes | grep comment`

```
           batch_action_admin_user_comments POST       /admin/user_comments/batch_action(.:format)            admin/user_comments#batch_action
                        admin_user_comments GET        /admin/user_comments(.:format)                         admin/user_comments#index
                                            POST       /admin/user_comments(.:format)                         admin/user_comments#create
                     new_admin_user_comment GET        /admin/user_comments/new(.:format)                     admin/user_comments#new
                    edit_admin_user_comment GET        /admin/user_comments/:id/edit(.:format)                admin/user_comments#edit
                         admin_user_comment GET        /admin/user_comments/:id(.:format)                     admin/user_comments#show
                                            PATCH      /admin/user_comments/:id(.:format)                     admin/user_comments#update
                                            PUT        /admin/user_comments/:id(.:format)                     admin/user_comments#update
                                            DELETE     /admin/user_comments/:id(.:format)                     admin/user_comments#destroy
                             admin_comments GET        /admin/comments(.:format)                              admin/comments#index
                                            POST       /admin/comments(.:format)                              admin/comments#create
                              admin_comment GET        /admin/comments/:id(.:format)                          admin/comments#show
                         api_photo_comments POST       /api/photos/:photo_id/comments(.:format)               api/comments#create
                     new_api_photo_comments GET        /api/photos/:photo_id/comments/new(.:format)           api/comments#new
                    edit_api_photo_comments GET        /api/photos/:photo_id/comments/edit(.:format)          api/comments#edit
                                            GET        /api/photos/:photo_id/comments(.:format)               api/comments#show
                                            PATCH      /api/photos/:photo_id/comments(.:format)               api/comments#update
                                            PUT        /api/photos/:photo_id/comments(.:format)               api/comments#update
                                            DELETE     /api/photos/:photo_id/comments(.:format)               api/comments#destroy

```

I tried to add `only: [:create, :index]` to my `comments` resource but only the `create` route is visible. 

According to the documentation about [nested-resources](http://guides.rubyonrails.org/routing.html#nested-resources) I don't understand what's happening. 

Thank you for your help.