From 10130fa7d6a2dca4250ada1144fcfcfe75c26f45 Mon Sep 17 00:00:00 2001 From: Karen Konou Date: Sun, 3 Feb 2019 20:27:28 +0100 Subject: made toggleable, added docs --- lib/pleroma/web/activity_pub/mrf/hellthread_policy.ex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/pleroma/web/activity_pub/mrf/hellthread_policy.ex b/lib/pleroma/web/activity_pub/mrf/hellthread_policy.ex index 0b9caeb11..53588b264 100644 --- a/lib/pleroma/web/activity_pub/mrf/hellthread_policy.ex +++ b/lib/pleroma/web/activity_pub/mrf/hellthread_policy.ex @@ -13,10 +13,10 @@ defmodule Pleroma.Web.ActivityPub.MRF.HellthreadPolicy do recipients = (object["to"] || []) ++ (object["cc"] || []) cond do - length(recipients) > reject_threshold -> + length(recipients) > reject_threshold and reject_threshold != 0 -> {:reject, nil} - length(recipients) > delist_threshold -> + length(recipients) > delist_threshold and delist_threshold != 0 -> if Enum.member?(object["to"], "https://www.w3.org/ns/activitystreams#Public") or Enum.member?(object["cc"], "https://www.w3.org/ns/activitystreams#Public") do object -- cgit v1.2.3