Fix Pleroma.FollowingRelationship.move_following/2
authorEgor Kislitsyn <egor@kislitsyn.com>
Tue, 3 Dec 2019 15:31:12 +0000 (22:31 +0700)
committerEgor Kislitsyn <egor@kislitsyn.com>
Tue, 3 Dec 2019 15:31:12 +0000 (22:31 +0700)
lib/pleroma/following_relationship.ex

index a03c9bd304c595bb6e16832866001328c4951a2f..0b0219b82c3b240aa77a486e748eb943a5ba7df4 100644 (file)
@@ -121,8 +121,12 @@ defmodule Pleroma.FollowingRelationship do
       Pleroma.Web.CommonAPI.follow(following_relationship.follower, target)
     end)
     |> case do
-      [] -> :ok
-      _ -> move_following(origin, target)
+      [] ->
+        User.update_follower_count(origin)
+        :ok
+
+      _ ->
+        move_following(origin, target)
     end
   end
 end