diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2016-11-09 17:48:44 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2016-11-09 17:48:44 +0100 |
commit | b13e7dda1f33be43d1667b754b67df71f3187a5c (patch) | |
tree | 62f451e95bb93846744f7bcdc58fcf8dc8d6d6f9 /config | |
parent | 8d7fc5da6c880e356e6861b5c5bd564c242c7991 (diff) |
API pagination for all collections using Link header
Diffstat (limited to 'config')
-rw-r--r-- | config/routes.rb | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/config/routes.rb b/config/routes.rb index 26b61b8e1..5916ffa42 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -67,14 +67,10 @@ Rails.application.routes.draw do end end - resources :timelines, only: [] do - collection do - get :home - get :mentions - get :public - get '/tag/:id', action: :tag - end - end + get '/timelines/home', to: 'timelines#home', as: :home_timeline + get '/timelines/mentions', to: 'timelines#mentions', as: :mentions_timeline + get '/timelines/public', to: 'timelines#public', as: :public_timeline + get '/timelines/tag/:id', to: 'timelines#tag', as: :hashtag_timeline resources :follows, only: [:create] resources :media, only: [:create] |