2016-08-03 10:03:05 +02:00
|
|
|
<?php
|
2017-01-18 22:45:32 +01:00
|
|
|
use \Friendica\Core\Config;
|
|
|
|
|
2016-08-03 10:03:05 +02:00
|
|
|
function cronjobs_run(&$argv, &$argc){
|
2017-02-27 00:16:49 +01:00
|
|
|
global $a;
|
2016-08-03 10:03:05 +02:00
|
|
|
|
|
|
|
require_once('include/datetime.php');
|
2016-08-03 10:19:46 +02:00
|
|
|
require_once('include/ostatus.php');
|
2016-08-03 10:03:05 +02:00
|
|
|
require_once('include/post_update.php');
|
2016-08-03 10:19:46 +02:00
|
|
|
require_once('mod/nodeinfo.php');
|
2016-08-03 10:03:05 +02:00
|
|
|
|
|
|
|
// No parameter set? So return
|
|
|
|
if ($argc <= 1)
|
|
|
|
return;
|
|
|
|
|
|
|
|
// Check OStatus conversations
|
|
|
|
// Check only conversations with mentions (for a longer time)
|
|
|
|
if ($argv[1] == 'ostatus_mentions') {
|
|
|
|
ostatus::check_conversations(true);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Check every conversation
|
|
|
|
if ($argv[1] == 'ostatus_conversations') {
|
|
|
|
ostatus::check_conversations(false);
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Call possible post update functions
|
|
|
|
// see include/post_update.php for more details
|
|
|
|
if ($argv[1] == 'post_update') {
|
|
|
|
post_update();
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
// update nodeinfo data
|
|
|
|
if ($argv[1] == 'nodeinfo') {
|
|
|
|
nodeinfo_cron();
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
return;
|
|
|
|
}
|