Fix #5050 - Use summary_large_image only with media attachments (#5219)

main
Eugen Rochko 2017-10-04 19:06:23 +02:00 committed by GitHub
parent 43577e9f59
commit b406e3cc4c
2 changed files with 2 additions and 2 deletions

View File

@ -17,7 +17,9 @@
- unless media.file.meta.nil? - unless media.file.meta.nil?
= opengraph 'og:video:width', media.file.meta['small']['width'] = opengraph 'og:video:width', media.file.meta['small']['width']
= opengraph 'og:video:height', media.file.meta['small']['height'] = opengraph 'og:video:height', media.file.meta['small']['height']
= opengraph 'twitter:card', 'summary_large_image'
- else - else
= opengraph 'og:image', full_asset_url(account.avatar.url(:original)) = opengraph 'og:image', full_asset_url(account.avatar.url(:original))
= opengraph 'og:image:width', '120' = opengraph 'og:image:width', '120'
= opengraph 'og:image:height','120' = opengraph 'og:image:height','120'
= opengraph 'twitter:card', 'summary'

View File

@ -14,8 +14,6 @@
= render 'stream_entries/og_description', activity: @stream_entry.activity = render 'stream_entries/og_description', activity: @stream_entry.activity
= render 'stream_entries/og_image', activity: @stream_entry.activity, account: @account = render 'stream_entries/og_image', activity: @stream_entry.activity, account: @account
= opengraph 'twitter:card', 'summary_large_image'
- if show_landing_strip? - if show_landing_strip?
= render partial: 'shared/landing_strip', locals: { account: @stream_entry.account } = render partial: 'shared/landing_strip', locals: { account: @stream_entry.account }