diff options
author | Roger Braun <roger@rogerbraun.net> | 2017-10-31 14:53:14 +0100 |
---|---|---|
committer | Roger Braun <roger@rogerbraun.net> | 2017-10-31 14:53:14 +0100 |
commit | 997c01be53ecb5ee65dccb84c5f21df334bea812 (patch) | |
tree | 8ef4424283031bfb6184926eb2b89acc7cc3d706 /lib | |
parent | f23edd2d6b67ee30ccd16b7a27d9e07a9f928574 (diff) | |
parent | 968a546d4ac7d6b50af84aea71b3b37af8f2f669 (diff) | |
download | pleroma-997c01be53ecb5ee65dccb84c5f21df334bea812.tar.gz pleroma-997c01be53ecb5ee65dccb84c5f21df334bea812.zip |
Merge branch 'feature/mastodon-api-fixes' into develop
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pleroma/web/mastodon_api/views/status_view.ex | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/pleroma/web/mastodon_api/views/status_view.ex b/lib/pleroma/web/mastodon_api/views/status_view.ex index 272f83b2a..48703e657 100644 --- a/lib/pleroma/web/mastodon_api/views/status_view.ex +++ b/lib/pleroma/web/mastodon_api/views/status_view.ex @@ -21,9 +21,9 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do |> Enum.map(fn (user) -> AccountView.render("mention.json", %{user: user}) end) %{ - id: activity.id, + id: to_string(activity.id), uri: object, - url: nil, + url: nil, # TODO: This might be wrong, check with mastodon. account: AccountView.render("account.json", %{user: user}), in_reply_to_id: nil, in_reply_to_account_id: nil, @@ -78,9 +78,9 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do |> Enum.map(fn {name, url} -> %{ shortcode: name, url: url, static_url: url } end) %{ - id: activity.id, + id: to_string(activity.id), uri: object["id"], - url: object["external_url"], + url: object["external_url"] || object["id"], account: AccountView.render("account.json", %{user: user}), in_reply_to_id: reply_to && reply_to.id, in_reply_to_account_id: reply_to_user && reply_to_user.id, |