diff options
author | Effy Elden <github@effy.is> | 2017-04-17 01:41:33 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-04-17 01:41:33 +1000 |
commit | acd33101c50ba0cf09c1c41616f919d37760f3f7 (patch) | |
tree | 43564c181a7f58ce7471026bd0daa099344330e8 /app/views/stream_entries/show.html.haml | |
parent | fd81916e8625e5de39855522300eaeffd85ee13d (diff) | |
parent | 99226aba9391535a20d3cc6dba0f45e5792c73d4 (diff) |
Merge branch 'master' into fix/cache_blocking
Diffstat (limited to 'app/views/stream_entries/show.html.haml')
-rw-r--r-- | app/views/stream_entries/show.html.haml | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/app/views/stream_entries/show.html.haml b/app/views/stream_entries/show.html.haml index eb8387ccb..dea5e9d40 100644 --- a/app/views/stream_entries/show.html.haml +++ b/app/views/stream_entries/show.html.haml @@ -6,17 +6,8 @@ %meta{ property: 'og:type', content: 'article' }/ %meta{ property: 'og:title', content: "#{@account.username} on #{Rails.configuration.x.local_domain}" }/ - - if @stream_entry.activity.is_a?(Status) && !@stream_entry.activity.spoiler_text.blank? - %meta{ property: 'og:description', content: @stream_entry.activity.spoiler_text }/ - - else - %meta{ property: 'og:description', content: @stream_entry.activity.content }/ - - - if @stream_entry.activity.is_a?(Status) && !@stream_entry.activity.sensitive? && @stream_entry.activity.media_attachments.size > 0 - %meta{ property: 'og:image', content: full_asset_url(@stream_entry.activity.media_attachments.first.file.url(:small)) }/ - - else - %meta{ property: 'og:image', content: full_asset_url(@account.avatar.url(:original)) }/ - %meta{ property: 'og:image:width', content: '120' }/ - %meta{ property: 'og:image:height', content: '120' }/ + = render 'stream_entries/og_description', activity: @stream_entry.activity + = render 'stream_entries/og_image', activity: @stream_entry.activity, account: @account %meta{ property: 'twitter:card', content: 'summary' }/ |