aboutsummaryrefslogtreecommitdiff
path: root/lib/pleroma/web/mastodon_api
diff options
context:
space:
mode:
authorkaniini <ariadne@dereferenced.org>2019-10-05 10:00:05 +0000
committerkaniini <ariadne@dereferenced.org>2019-10-05 10:00:05 +0000
commite07e9cb75e6605218acea1ef41772ca29124bd0d (patch)
tree2a79aae59c6ce7500d360ba35a5b0aafe2146072 /lib/pleroma/web/mastodon_api
parent9c47d8571c6c46503d9bb836aea933eda6e9e0a5 (diff)
downloadpleroma-e07e9cb75e6605218acea1ef41772ca29124bd0d.tar.gz
Revert "Merge branch 'user-info-unread-direct-conversation' into 'develop'"
This reverts merge request !1737
Diffstat (limited to 'lib/pleroma/web/mastodon_api')
-rw-r--r--lib/pleroma/web/mastodon_api/views/account_view.ex11
1 files changed, 0 insertions, 11 deletions
diff --git a/lib/pleroma/web/mastodon_api/views/account_view.ex b/lib/pleroma/web/mastodon_api/views/account_view.ex
index 2d4976891..99169ef95 100644
--- a/lib/pleroma/web/mastodon_api/views/account_view.ex
+++ b/lib/pleroma/web/mastodon_api/views/account_view.ex
@@ -167,7 +167,6 @@ defmodule Pleroma.Web.MastodonAPI.AccountView do
|> maybe_put_chat_token(user, opts[:for], opts)
|> maybe_put_activation_status(user, opts[:for])
|> maybe_put_follow_requests_count(user, opts[:for])
- |> maybe_put_unread_conversation_count(user, opts[:for])
end
defp username_from_nickname(string) when is_binary(string) do
@@ -249,16 +248,6 @@ defmodule Pleroma.Web.MastodonAPI.AccountView do
defp maybe_put_activation_status(data, _, _), do: data
- defp maybe_put_unread_conversation_count(data, %User{id: user_id} = user, %User{id: user_id}) do
- data
- |> Kernel.put_in(
- [:pleroma, :unread_conversation_count],
- user.info.unread_conversation_count
- )
- end
-
- defp maybe_put_unread_conversation_count(data, _, _), do: data
-
defp image_url(%{"url" => [%{"href" => href} | _]}), do: href
defp image_url(_), do: nil
end