From: Roland Häder Date: Mon, 17 Jul 2023 12:56:56 +0000 (+0200) Subject: Fixed: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=bcd2b1c5232a2e3dc95acaed46a704634ab42a84;p=friendica.git Fixed: - allow administrator to choose whether the blocklist is published under `/about` or later any other API (e.g. common is `/api/v1/instance/domain_blocks`). --- diff --git a/src/Module/Friendica.php b/src/Module/Friendica.php index c6e2768bd3..2dbe5d7a9d 100644 --- a/src/Module/Friendica.php +++ b/src/Module/Friendica.php @@ -94,8 +94,7 @@ class Friendica extends BaseModule $blockList = $this->config->get('system', 'blocklist') ?? []; - $register_policy_int = $this->config->get('config', 'register_policy'); - if (!empty($blockList) && ($register_policy_int !== Register::CLOSED || $this->session->isAuthenticated())) { + if (!empty($blockList) && ($this->config->get('blocklist', 'published') || $this->session->isAuthenticated())) { $blocked = [ 'title' => $this->t('On this server the following remote servers are blocked.'), 'header' => [ diff --git a/static/defaults.config.php b/static/defaults.config.php index e8f44613ce..e2ce631d0d 100644 --- a/static/defaults.config.php +++ b/static/defaults.config.php @@ -786,4 +786,9 @@ return [ // Banner for Mastodon API 'mastodon_banner' => '/images/friendica-banner.jpg', ], + 'blocklist' => [ + // published (Boolean) + // Wether the blocklist is published under /about (or any later API) + 'published' => true, + ], ];