Added get_stripped_html_for_object. Renamed a few things
[akkoma] / lib / pleroma / web / mastodon_api / views / status_view.ex
index d06da812cd13d21c56341923b1cd46ac0082d0f5..05ed602d595728f48af862152c8bb07cd65a4b49 100644 (file)
@@ -1,3 +1,7 @@
+# Pleroma: A lightweight social networking server
+# Copyright © 2017-2018 Pleroma Authors <https://pleroma.social/>
+# SPDX-License-Identifier: AGPL-3.0-only
+
 defmodule Pleroma.Web.MastodonAPI.StatusView do
   use Pleroma.Web, :view
 
@@ -116,7 +120,7 @@ defmodule Pleroma.Web.MastodonAPI.StatusView do
     content =
       object
       |> render_content()
-      |> HTML.filter_tags(User.html_filter_policy(opts[:for]))
+      |> Utils.get_scrubbed_html_for_object(User.html_filter_policy(opts[:for]), activity)
 
     %{
       id: to_string(activity.id),