forked from AkkomaGang/akkoma
Use maybe_direct_follow for follow imports
This commit is contained in:
parent
c93571b87e
commit
7562912f6a
1 changed files with 1 additions and 1 deletions
|
@ -223,7 +223,7 @@ def follow_import(%{assigns: %{user: user}} = conn, %{"list" => list}) do
|
||||||
|> Enum.map(fn account ->
|
|> Enum.map(fn account ->
|
||||||
with %User{} = follower <- User.get_cached_by_ap_id(user.ap_id),
|
with %User{} = follower <- User.get_cached_by_ap_id(user.ap_id),
|
||||||
%User{} = followed <- User.get_or_fetch(account),
|
%User{} = followed <- User.get_or_fetch(account),
|
||||||
{:ok, follower} <- User.follow(follower, followed) do
|
{:ok, follower} <- User.maybe_direct_follow(follower, followed) do
|
||||||
ActivityPub.follow(follower, followed)
|
ActivityPub.follow(follower, followed)
|
||||||
else
|
else
|
||||||
err -> Logger.debug("follow_import: following #{account} failed with #{inspect(err)}")
|
err -> Logger.debug("follow_import: following #{account} failed with #{inspect(err)}")
|
||||||
|
|
Loading…
Reference in a new issue