MastoAPI account_view.ex: requested is false when following is true

Closes: https://git.pleroma.social/pleroma/pleroma/issues/903
This commit is contained in:
Haelwenn (lanodan) Monnier 2019-05-17 07:34:52 +02:00
parent 99f50bf3e8
commit 68c75a08e8
No known key found for this signature in database
GPG Key ID: D5B7A8E43C997DEE
1 changed files with 1 additions and 1 deletions

View File

@ -40,7 +40,7 @@ defmodule Pleroma.Web.MastodonAPI.AccountView do
follow_activity = Pleroma.Web.ActivityPub.Utils.fetch_latest_follow(user, target)
requested =
if follow_activity do
if follow_activity and !User.following?(target, user) do
follow_activity.data["state"] == "pending"
else
false