Better checking of previous follow request attempts
This commit is contained in:
parent
3989ec508c
commit
a176914c73
1 changed files with 1 additions and 1 deletions
|
@ -65,7 +65,7 @@ defp outstanding_follow_request_since?(
|
|||
|> Queries.by_object_id()
|
||||
|> Queries.by_type("Follow")
|
||||
|> where([a], a.inserted_at > ^since_datetime)
|
||||
|> where([a], fragment("? ->> 'state' = 'pending'", a.data))
|
||||
|> where([a], fragment("? ->> 'state' != 'accept'", a.data))
|
||||
|> where([a], a.actor == ^follower_id)
|
||||
|> Repo.exists?()
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue