From 83db0a8f3e48729043481a814db434124edc9cba Mon Sep 17 00:00:00 2001 From: Benjamin Neff <benjamin@coding4coffee.ch> Date: Wed, 3 Aug 2016 01:12:06 +0200 Subject: [PATCH] remove activity_streams, because it was always false ... --- app/models/post.rb | 4 ---- app/views/reshares/_reshare.mobile.haml | 5 ++--- app/views/shared/_photo_area.mobile.haml | 3 --- app/views/shared/_post_info.mobile.haml | 4 +--- app/views/status_messages/_status_message.mobile.haml | 2 -- 5 files changed, 3 insertions(+), 15 deletions(-) diff --git a/app/models/post.rb b/app/models/post.rb index cb94c408ad..e101c5d3f6 100644 --- a/app/models/post.rb +++ b/app/models/post.rb @@ -129,10 +129,6 @@ class Post < ActiveRecord::Base new(params.to_hash.stringify_keys.slice(*column_names, "author")) end - def activity_streams? - false - end - def comment_email_subject I18n.t('notifier.a_post_you_shared') end diff --git a/app/views/reshares/_reshare.mobile.haml b/app/views/reshares/_reshare.mobile.haml index 16d0934689..871791cff8 100644 --- a/app/views/reshares/_reshare.mobile.haml +++ b/app/views/reshares/_reshare.mobile.haml @@ -13,9 +13,8 @@ - unless post.is_a?(Reshare) = render "shared/nsfw_shield", post: post - - if !post.activity_streams? - .nsfw-hidden - = render "status_messages/status_message", post: post, photos: post.photos + .nsfw-hidden + = render "status_messages/status_message", post: post, photos: post.photos - else .content = t(".deleted") diff --git a/app/views/shared/_photo_area.mobile.haml b/app/views/shared/_photo_area.mobile.haml index 78ac89a408..19417b9155 100644 --- a/app/views/shared/_photo_area.mobile.haml +++ b/app/views/shared/_photo_area.mobile.haml @@ -11,6 +11,3 @@ .additional_photo_count = "+ #{post.photos.size-1}" = image_tag post.photos.first.url(:thumb_large), class: "stream-photo big-stream-photo" - - elsif post.activity_streams? - = image_tag post.image_url - diff --git a/app/views/shared/_post_info.mobile.haml b/app/views/shared/_post_info.mobile.haml index 174b91b11d..1b51261f26 100644 --- a/app/views/shared/_post_info.mobile.haml +++ b/app/views/shared/_post_info.mobile.haml @@ -20,9 +20,7 @@ = link_to(post_path(post)) do = timeago(post.created_at) %span.via - - if post.activity_streams? - = t('shared.stream_element.via', link: link_to("#{post.provider_display_name}", post.actor_url)).html_safe - - elsif post.provider_display_name == 'mobile' + - if post.provider_display_name == "mobile" = t('shared.stream_element.via_mobile', link: nil) – %span.scope_scope diff --git a/app/views/status_messages/_status_message.mobile.haml b/app/views/status_messages/_status_message.mobile.haml index 52f60ba74d..51881e1da4 100644 --- a/app/views/status_messages/_status_message.mobile.haml +++ b/app/views/status_messages/_status_message.mobile.haml @@ -11,8 +11,6 @@ .additional_photo_count = "+ #{post.photos.size-1}" = image_tag post.first_photo_url(:thumb_large), :class => "stream-photo big-stream-photo" - - elsif post.activity_streams? - = image_tag post.image_url %div{:class => direction_for(post.text)} != post.message.markdownified -- GitLab