use Friendica\BaseObject;
use Friendica\Core\Addon;
use Friendica\Database\DBA;
-use Friendica\Util\Network;
/**
* Model interaction for the nodeinfo
return;
}
- $logger->info('cron_start');
-
$userStats = User::getStatistics();
$config->set('nodeinfo', 'total_users', $userStats['total_users']);
$local_comments = DBA::count('item', ["`origin` AND `id` != `parent` AND NOT `deleted` AND `uid` != 0"]);
$config->set('nodeinfo', 'local_comments', $local_comments);
$logger->debug('item statistics', ['local_comments' => $local_comments]);
-
- // Now trying to register
- $url = 'http://the-federation.info/register/' . $app->getHostName();
- $logger->debug('Check registering url', ['url' => $url]);
- $ret = Network::fetchUrl($url);
- $logger->debug('Check registering answer', ['answer' => $ret]);
-
- $logger->info('cron_end');
}
}
use Friendica\Model\User;
use Friendica\Network\Probe;
use Friendica\Protocol\PortableContact;
+use Friendica\Util\Network;
use Friendica\Util\Proxy as ProxyUtils;
require_once 'mod/nodeinfo.php';
break;
case 'nodeinfo':
+ Logger::info('cron_start');
Nodeinfo::update();
+ // Now trying to register
+ $url = 'http://the-federation.info/register/' . $app->getHostName();
+ Logger::debug('Check registering url', ['url' => $url]);
+ $ret = Network::fetchUrl($url);
+ Logger::debug('Check registering answer', ['answer' => $ret]);
+ Logger::info('cron_end');
break;
case 'expire_and_remove_users':