Merge pull request 'Add maintenance query to remove memid=0 emails' (!2) from fix-email-address-maintenance-bug-1543 into main
Reviewed-on: #2 Reviewed-by: Brian Mc Cullough <bmccullough@cacert.org> Reviewed-by: Dirk Astrath <dirk@cacert.org>
This commit is contained in:
commit
e021736c47
1 changed files with 6 additions and 0 deletions
|
@ -39,6 +39,12 @@
|
|||
(UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(`created`)) >= 172800";
|
||||
mysql_query($query);
|
||||
|
||||
// removes entries that where introduced due to missing/wrong default value
|
||||
// in MariaDB strict mode, see https://bugs.cacert.org/view.php?id=1543
|
||||
$query = "delete from `email` where `memid`=0 and
|
||||
(UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(`created`)) >= 172800";
|
||||
mysql_query($query);
|
||||
|
||||
$query = "delete from `disputedomain` where `hash`!='' and
|
||||
(UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(`created`)) >= 21600";
|
||||
mysql_query($query);
|
||||
|
|
Loading…
Reference in a new issue