about summary refs log tree commit diff
path: root/config/routes.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2017-08-30 10:23:43 +0200
committerGitHub <noreply@github.com>2017-08-30 10:23:43 +0200
commite95bdec7c5da63930fc2e08e67e4358fec19296d (patch)
treee586a3f4de5730387d33bf7108bce1b00a761595 /config/routes.rb
parentfcca31350d05064a117c5f1c1b014875dc12afd3 (diff)
Update status embeds (#4742)
- Use statuses controller for embeds instead of stream entries controller
- Prefer /@:username/:id/embed URL for embeds
- Use /@:username as author_url in OEmbed
- Add follow link to embeds which opens web intent in new window
- Use redis cache in development
- Cache entire embed
Diffstat (limited to 'config/routes.rb')
-rw-r--r--config/routes.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/config/routes.rb b/config/routes.rb
index 7588805c0..f8f145e1d 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -44,6 +44,7 @@ Rails.application.routes.draw do
     resources :statuses, only: [:show] do
       member do
         get :activity
+        get :embed
       end
     end
 
@@ -59,6 +60,7 @@ Rails.application.routes.draw do
   get '/@:username/with_replies', to: 'accounts#show', as: :short_account_with_replies
   get '/@:username/media', to: 'accounts#show', as: :short_account_media
   get '/@:account_username/:id', to: 'statuses#show', as: :short_account_status
+  get '/@:account_username/:id/embed', to: 'statuses#embed', as: :embed_short_account_status
 
   namespace :settings do
     resource :profile, only: [:show, :update]