Secondly, the current route resolves to address.com/people/{:id} and I would like to it resolve to address.com/{:user_name} and I am not sure how to get this to work. I have tried a few different options but I am not quite sure what I am doing here.
resources :people, only: [:index, :show] do resources :pubs, except: [:create, :new, :edit, :destroy] end
I have attempted to add —> get 'people/:id/user_name' => 'people#user_name', as: :user_name but this has not worked.