1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-31 22:10:45 +02:00

[ticket/11373] Prune old read notifications with cron

PHPBB3-11373
This commit is contained in:
Nathan Guse
2013-07-27 20:37:50 -05:00
parent 26dac64d45
commit a79e3b3415
5 changed files with 110 additions and 5 deletions

View File

@@ -0,0 +1,25 @@
<?php
/**
*
* @package migration
* @copyright (c) 2013 phpBB Group
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
*
*/
class phpbb_db_migration_data_310_notifications_cron extends phpbb_db_migration
{
static public function depends_on()
{
return array('phpbb_db_migration_data_310_notifications');
}
public function update_data()
{
return array(
array('config.add', array('read_notification_expire_days', 30)),
array('config.add', array('read_notification_last_gc', 0)), // last run
array('config.add', array('read_notification_gc', (60 * 60 * 24))), // seconds between run; 1 day
);
}
}