commit: 769b1ebbe0de2e3c9929add50bc18718055690d1
parent: 22a8801dbc77d2d01b326a7cb89d1a28b054e073
Author: Eugen Rochko <eugen@zeonfederated.com>
Date: Sun, 9 Oct 2016 15:05:07 +0200
Filter block users and reblogs of them from public timeline
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/channels/public_channel.rb b/app/channels/public_channel.rb
@@ -5,7 +5,7 @@ class PublicChannel < ApplicationCable::Channel
message = ActiveSupport::JSON.decode(encoded_message)
status = Status.find_by(id: message['id'])
- next if status.nil?
+ next if status.nil? || current_user.account.blocking?(status.account) || (status.reblog? && current_user.account.blocking?(status.reblog.account))
message['message'] = FeedManager.instance.inline_render(current_user.account, status)