mastodon api: add support for rendering Page objects
authorWilliam Pitcock <nenolod@dereferenced.org>
Thu, 1 Nov 2018 10:00:16 +0000 (10:00 +0000)
committerWilliam Pitcock <nenolod@dereferenced.org>
Thu, 1 Nov 2018 10:00:16 +0000 (10:00 +0000)
lib/pleroma/web/mastodon_api/views/status_view.ex

index 1efd994709fb6a2765f3588d590d5e47340621dc..27fe23594f07ae849d77477efeccfebb73a7d2f1 100644 (file)
@@ -236,7 +236,7 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do
     content
   end
 
-  def render_content(%{"type" => "Article"} = object) do
+  def render_content(%{"type" => object_type} = object) when object_type in ["Article", "Page"] do
     summary = object["name"]
 
     content =