From 4289ed1d13b9c3b91663581c44635105c4bc0412 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 23 May 2017 12:11:39 -0400 Subject: Refactor of API timeline actions (#3263) - Increase coverage to exercise all parts of each action - Move into namespace to share common code - Misc refactor of each action for smaller methods, simpler code --- config/routes.rb | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'config') diff --git a/config/routes.rb b/config/routes.rb index e3c6ce156..81c205daa 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -136,9 +136,11 @@ Rails.application.routes.draw do end end - get '/timelines/home', to: 'timelines#home', as: :home_timeline - get '/timelines/public', to: 'timelines#public', as: :public_timeline - get '/timelines/tag/:id', to: 'timelines#tag', as: :hashtag_timeline + namespace :timelines do + resource :home, only: :show, controller: :home + resource :public, only: :show, controller: :public + resources :tag, only: :show + end get '/search', to: 'search#index', as: :search -- cgit