X-Git-Url: https://git.squeep.com/?a=blobdiff_plain;f=lib%2Fpleroma%2Fweb%2Fpleroma_api%2Fviews%2Fchat_message_view.ex;h=b088a87346fd0cee75b13b30daeb29eb54d43ffd;hb=904295d53b82fcfd7dfefd4c970815b36f06faf0;hp=a821479ab7a3fac98a0bbc73707b01fb3c4c8a46;hpb=b5dc59c8fa587b4db844c7fc0ba16e5cb00bfd38;p=akkoma diff --git a/lib/pleroma/web/pleroma_api/views/chat_message_view.ex b/lib/pleroma/web/pleroma_api/views/chat_message_view.ex index a821479ab..b088a8734 100644 --- a/lib/pleroma/web/pleroma_api/views/chat_message_view.ex +++ b/lib/pleroma/web/pleroma_api/views/chat_message_view.ex @@ -23,7 +23,10 @@ defmodule Pleroma.Web.PleromaAPI.ChatMessageView do chat_id: chat_id |> to_string(), account_id: User.get_cached_by_ap_id(chat_message["actor"]).id, created_at: Utils.to_masto_date(chat_message["published"]), - emojis: StatusView.build_emojis(chat_message["emoji"]) + emojis: StatusView.build_emojis(chat_message["emoji"]), + attachment: + chat_message["attachment"] && + StatusView.render("attachment.json", attachment: chat_message["attachment"]) } end