about summary refs log tree commit diff
path: root/app/views
diff options
context:
space:
mode:
authorIsabelle Knott <isabelle@blackle-mori.com>2017-04-13 09:59:43 -0400
committerEugen <eugen@zeonfederated.com>2017-04-13 15:59:43 +0200
commit447b8bc44eb33ae6ffdfbcc7ae52fbe0bba93ece (patch)
tree8ee67c8d1a8b10c063406e53a9fe6b7c468c143a /app/views
parent093879c1778a525b7aa9b847b58e9ce6604b5acf (diff)
Do not show media attachment as og:image if it was marked as NSFW (#1693)
Diffstat (limited to 'app/views')
-rw-r--r--app/views/stream_entries/show.html.haml2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/views/stream_entries/show.html.haml b/app/views/stream_entries/show.html.haml
index f37fb7919..862946750 100644
--- a/app/views/stream_entries/show.html.haml
+++ b/app/views/stream_entries/show.html.haml
@@ -11,7 +11,7 @@
   - else
     %meta{ property: 'og:description', content: @stream_entry.activity.content }/
 
-  - if @stream_entry.activity.is_a?(Status) && @stream_entry.activity.media_attachments.size > 0
+  - 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)) }/