X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Ffriendica.php;h=e75e9cebaeda19828c79a9df552eaa656d8e5336;hb=1d745c25a7b067951ea24c69209b9a54fbbe8c5d;hp=6c143634caf980ae9cc430e46dfc8c53f0b380ca;hpb=334d3921549a538130220f8b627f39f3e0877e26;p=friendica.git diff --git a/mod/friendica.php b/mod/friendica.php index 6c143634ca..e75e9cebae 100644 --- a/mod/friendica.php +++ b/mod/friendica.php @@ -11,7 +11,7 @@ use Friendica\Database\DBM; function friendica_init(App $a) { - if ($a->argv[1] == "json") { + if (!empty($a->argv[1]) && ($a->argv[1] == "json")) { $register_policy = ['REGISTER_CLOSED', 'REGISTER_APPROVE', 'REGISTER_OPEN']; $sql_extra = ''; @@ -116,14 +116,14 @@ function friendica_content(App $a) } else { $o .= '

' . L10n::t('No installed addons/apps') . '

' . PHP_EOL; } - + if (Config::get('system', 'tosdisplay')) { $o .= '

'.L10n::t('Read about the Terms of Service of this node.', System::baseurl()).'

'; } - $blocklist = Config::get('system', 'blocklist'); - if (count($blocklist)) { + $blocklist = Config::get('system', 'blocklist', []); + if (!empty($blocklist)) { $o .= '

' . L10n::t('On this server the following remote servers are blocked.') . '

' . PHP_EOL; $o .= '' . PHP_EOL; foreach ($blocklist as $b) {
' . L10n::t('Blocked domain') . '' . L10n::t('Reason for the block') . '