From: Haelwenn (lanodan) Monnier Date: Wed, 13 Jun 2018 22:26:37 +0000 (+0200) Subject: Fix attachement rendering X-Git-Url: https://git.squeep.com/?a=commitdiff_plain;h=3b8ef245326fb788a0345689c0ac5f01edc19361;p=akkoma Fix attachement rendering --- diff --git a/lib/pleroma/web/mastodon_api/views/status_view.ex b/lib/pleroma/web/mastodon_api/views/status_view.ex index 9625da822..7226a407e 100644 --- a/lib/pleroma/web/mastodon_api/views/status_view.ex +++ b/lib/pleroma/web/mastodon_api/views/status_view.ex @@ -152,9 +152,9 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do end def render("attachment.json", %{attachment: attachment}) do - [attachment | _] = attachment["url"] - media_type = attachment["mediaType"] || attachment["mimeType"] - href = attachment["href"] + [attachment_url | _] = attachment["url"] + media_type = attachment_url["mediaType"] || attachment_url["mimeType"] + href = attachment_url["href"] type = cond do