prune_hub_reinstalls() and add cron weekly as a side effect

This commit is contained in:
friendica
2014-03-19 19:53:14 -07:00
parent afca10a071
commit 68fc2a220e
3 changed files with 50 additions and 1 deletions

View File

@@ -105,6 +105,23 @@ function poller_run($argv, $argc){
if($d2 != intval($d1)) {
$d3 = intval(datetime_convert('UTC','UTC','now','N'));
if($d3 == 7) {
/**
* Cron Weekly
*
* Actions in the following block are executed once per day only on Sunday (once per week).
*
*/
require_once('include/hubloc.php');
prune_hub_reinstalls();
}
// expire any read notifications over a month old
q("delete from notify where seen = 1 and date < UTC_TIMESTAMP() - INTERVAL 30 DAY");