1
0
Fork 0

Worked in fermionic's comments (not count($r)).

This commit is contained in:
zottel 2012-11-04 11:07:11 +01:00
parent 6aca58f320
commit dd1e735efb

View file

@ -71,7 +71,7 @@ function poller_run($argv, $argc){
// delete user and contact records for recently removed accounts // 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"); $r = q("SELECT * FROM `user` WHERE `account_removed` = 1 AND `account_expires_on` < UTC_TIMESTAMP() - INTERVAL 3 DAY");
if (count($r)) { if ($r) {
foreach($r as $user) { foreach($r as $user) {
q("DELETE FROM `contact` WHERE `uid` = %d", intval($user['uid'])); q("DELETE FROM `contact` WHERE `uid` = %d", intval($user['uid']));
q("DELETE FROM `user` WHERE `uid` = %d", intval($user['uid'])); q("DELETE FROM `user` WHERE `uid` = %d", intval($user['uid']));