mirror of
https://github.com/friendica/friendica
synced 2025-04-26 18:30:11 +00:00
Diaspora: Auto-adding users as friend who already sharing with us
This commit is contained in:
parent
452ff19d73
commit
7ab335c9d6
6 changed files with 33 additions and 18 deletions
|
@ -9,7 +9,7 @@ function poller_run(&$argv, &$argc){
|
|||
if(is_null($a)) {
|
||||
$a = new App;
|
||||
}
|
||||
|
||||
|
||||
if(is_null($db)) {
|
||||
@include(".htconfig.php");
|
||||
require_once("include/dba.php");
|
||||
|
@ -57,17 +57,17 @@ function poller_run(&$argv, &$argc){
|
|||
load_hooks();
|
||||
|
||||
logger('poller: start');
|
||||
|
||||
|
||||
// run queue delivery process in the background
|
||||
|
||||
proc_run('php',"include/queue.php");
|
||||
|
||||
|
||||
// expire any expired accounts
|
||||
|
||||
q("UPDATE user SET `account_expired` = 1 where `account_expired` = 0
|
||||
AND `account_expires_on` != '0000-00-00 00:00:00'
|
||||
AND `account_expires_on` < UTC_TIMESTAMP() ");
|
||||
|
||||
|
||||
// delete user and contact records for recently removed accounts
|
||||
|
||||
$r = q("SELECT * FROM `user` WHERE `account_removed` = 1 AND `account_expires_on` < UTC_TIMESTAMP() - INTERVAL 3 DAY");
|
||||
|
@ -77,12 +77,12 @@ function poller_run(&$argv, &$argc){
|
|||
q("DELETE FROM `user` WHERE `uid` = %d", intval($user['uid']));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$abandon_days = intval(get_config('system','account_abandon_days'));
|
||||
if($abandon_days < 1)
|
||||
$abandon_days = 0;
|
||||
|
||||
|
||||
|
||||
|
||||
// once daily run birthday_updates and then expire in background
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue