Commit a938d07d authored by eal's avatar eal
Browse files

Merge branch 'bugfix/mastofe_thread_render' into 'develop'

lib/pleroma/web/mastodon_api/views/status_view.ex: Fix status.json so it renders threads

See merge request !223
parents 00d7d109 72c2915e
Pipeline #2473 passed with stages
in 4 minutes and 27 seconds
......@@ -125,8 +125,8 @@ def render("status.json", %{activity: %{data: %{"object" => object}} = activity}
uri: object["id"],
url: object["external_url"] || object["id"],
account: AccountView.render("account.json", %{user: user}),
in_reply_to_id: reply_to &&,
in_reply_to_account_id: reply_to_user &&,
in_reply_to_id: reply_to && to_string(,
in_reply_to_account_id: reply_to_user && to_string(,
reblog: nil,
content: HtmlSanitizeEx.basic_html(object["content"]),
created_at: created_at,
......@@ -64,11 +64,11 @@ test "a reply" do
status = StatusView.render("status.json", %{activity: activity})
assert status.in_reply_to_id ==
assert status.in_reply_to_id == to_string(
[status] = StatusView.render("index.json", %{activities: [activity], as: :activity})
assert status.in_reply_to_id ==
assert status.in_reply_to_id == to_string(
test "contains mentions" do
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment