Skip to content
Snippets Groups Projects
Commit 78588dbd authored by kaniini's avatar kaniini
Browse files

mrf: simple policy: mark all posts instead of posts with media as sensitive if...

mrf: simple policy: mark all posts instead of posts with media as sensitive if they match media_nsfw
parent d2dacadb
No related branches found
No related tags found
No related merge requests found
......@@ -48,10 +48,9 @@ defmodule Pleroma.Web.ActivityPub.MRF.SimplePolicy do
%{host: actor_host} = _actor_info,
%{
"type" => "Create",
"object" => %{"attachment" => child_attachment} = child_object
"object" => child_object
} = object
)
when length(child_attachment) > 0 do
) do
object =
if Enum.member?(Pleroma.Config.get([:mrf_simple, :media_nsfw]), actor_host) do
tags = (child_object["tag"] || []) ++ ["nsfw"]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment