about summary refs log tree commit diff
path: root/app/workers/thread_resolve_worker.rb
diff options
context:
space:
mode:
authorFire Demon <firedemon@creature.cafe>2020-08-20 06:12:37 -0500
committerFire Demon <firedemon@creature.cafe>2020-08-30 05:45:19 -0500
commita1d1ee39f79c5bd836dffa676c938c1d2c5e79ec (patch)
treefa1f5ea5f5d1ffcde4112c0b2228a899c0adf888 /app/workers/thread_resolve_worker.rb
parent00d24f263fe54e5f7ccf785666254232ebb07085 (diff)
[Privacy] Choose random local follower for private fetches instead of first
Diffstat (limited to 'app/workers/thread_resolve_worker.rb')
-rw-r--r--app/workers/thread_resolve_worker.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/workers/thread_resolve_worker.rb b/app/workers/thread_resolve_worker.rb
index e362b5b2b..7599eb784 100644
--- a/app/workers/thread_resolve_worker.rb
+++ b/app/workers/thread_resolve_worker.rb
@@ -8,7 +8,7 @@ class ThreadResolveWorker
 
   def perform(child_status_id, parent_url, on_behalf_of = nil)
     child_status  = Status.find(child_status_id)
-    on_behalf_of  = child_status.account.followers.local.first if on_behalf_of.nil? && !child_status.distributable?
+    on_behalf_of  = child_status.account.followers.local.random.first if on_behalf_of.nil? && !child_status.distributable?
     parent_status = FetchRemoteStatusService.new.call(parent_url, nil, on_behalf_of)
 
     return if parent_status.nil?