Notifies her contacts when a user looses her last redirection (Closes #1000).
[platal.git] / bin / cron / notifs.send.php
index 1d5ceca..abaa47d 100755 (executable)
@@ -36,8 +36,11 @@ foreach ($all->_data as $u) {
     $mailer->send($u['mail_fmt'] == 'html');
 }
 
-XDB::execute("DELETE FROM  watch_profile
-                    WHERE  ts < DATE_SUB(CURRENT_DATE, INTERVAL 15 DAY)");
+XDB::execute("UPDATE  watch_profile
+                 SET  ts = NOW()
+               WHERE  field = 'broken'");
+XDB::execute('DELETE FROM  watch_profile
+                    WHERE  ts < DATE_SUB(CURRENT_DATE, INTERVAL 15 DAY)');
 
 // vim:set et sw=4 sts=4 sws=4 foldmethod=marker enc=utf-8:
 ?>