about summary refs log tree commit diff
path: root/app/services/follow_service.rb
diff options
context:
space:
mode:
authorThibG <thib@sitedethib.com>2020-02-25 18:05:52 +0100
committerGitHub <noreply@github.com>2020-02-25 18:05:52 +0100
commit9ee8e1add9f937a75c2514ca88958ff02cf5573c (patch)
treee6c97dfd5a14860b9c825b1c84fb1dd84ada6581 /app/services/follow_service.rb
parent0d41fef50618e3d58255b4f4082326e83ff06982 (diff)
parent2f2b48b227304d0f0a28dd4867e84af10b8097ad (diff)
Merge pull request #1289 from ThibG/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'app/services/follow_service.rb')
-rw-r--r--app/services/follow_service.rb5
1 files changed, 2 insertions, 3 deletions
diff --git a/app/services/follow_service.rb b/app/services/follow_service.rb
index dc47804c0..4d19002c4 100644
--- a/app/services/follow_service.rb
+++ b/app/services/follow_service.rb
@@ -18,14 +18,13 @@ class FollowService < BaseService
     if source_account.following?(target_account)
       # We're already following this account, but we'll call follow! again to
       # make sure the reblogs status is set correctly.
-      source_account.follow!(target_account, reblogs: reblogs)
-      return
+      return source_account.follow!(target_account, reblogs: reblogs)
     elsif source_account.requested?(target_account)
       # This isn't managed by a method in AccountInteractions, so we modify it
       # ourselves if necessary.
       req = source_account.follow_requests.find_by(target_account: target_account)
       req.update!(show_reblogs: reblogs)
-      return
+      return req
     end
 
     ActivityTracker.increment('activity:interactions')