diff options
author | Roger Braun <rbraun@Bobble.local> | 2017-09-13 16:05:39 +0200 |
---|---|---|
committer | Roger Braun <rbraun@Bobble.local> | 2017-09-13 16:05:39 +0200 |
commit | e6286152b94efcab355465875208e2a200760f03 (patch) | |
tree | d11cdf32c3852b9eecb29218f8f67a1842e164ec | |
parent | 49929321c761cf389d42ca52d88dc8ec09a375cc (diff) | |
download | pleroma-e6286152b94efcab355465875208e2a200760f03.tar.gz |
Fix logic.
-rw-r--r-- | lib/pleroma/web/mastodon_api/views/account_view.ex | 4 | ||||
-rw-r--r-- | test/web/mastodon_api/account_view_test.exs | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/lib/pleroma/web/mastodon_api/views/account_view.ex b/lib/pleroma/web/mastodon_api/views/account_view.ex index 4e9ee4132..4f65eb772 100644 --- a/lib/pleroma/web/mastodon_api/views/account_view.ex +++ b/lib/pleroma/web/mastodon_api/views/account_view.ex @@ -43,8 +43,8 @@ defmodule Pleroma.Web.MastodonAPI.AccountView do def render("relationship.json", %{user: user, target: target}) do %{ id: target.id, - following: User.following?(target, user), - followed_by: User.following?(user, target), + following: User.following?(user, target), + followed_by: User.following?(target, user), blocking: false, muting: false, requested: false, diff --git a/test/web/mastodon_api/account_view_test.exs b/test/web/mastodon_api/account_view_test.exs index 259258281..c8f33f98c 100644 --- a/test/web/mastodon_api/account_view_test.exs +++ b/test/web/mastodon_api/account_view_test.exs @@ -49,8 +49,8 @@ defmodule Pleroma.Web.MastodonAPI.AccountViewTest do expected = %{ id: other_user.id, - following: false, - followed_by: true, + following: true, + followed_by: false, blocking: false, muting: false, requested: false, |