1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-03-13 20:28:44 +01:00

[ticket/11731] Remove static calls to captcha garbage collector

PHPBB3-11731
This commit is contained in:
Andy Chase 2013-07-22 15:04:30 -07:00
parent b71038486e
commit 80f81dd0d2
2 changed files with 4 additions and 2 deletions

View File

@ -50,7 +50,8 @@ class phpbb_captcha_factory
{
include($phpbb_root_path . "includes/captcha/plugins/{$name}_plugin." . $phpEx);
}
call_user_func(array($name, 'garbage_collect'), 0);
$captcha = self::get_instance($name);
$captcha->garbage_collect(0);
}
/**

View File

@ -1022,7 +1022,8 @@ class phpbb_session
{
include($phpbb_root_path . "includes/captcha/captcha_factory." . $phpEx);
}
phpbb_captcha_factory::garbage_collect($config['captcha_plugin']);
$captcha_factory = new phpbb_captcha_factory();
$captcha_factory->garbage_collect($config['captcha_plugin']);
$sql = 'DELETE FROM ' . LOGIN_ATTEMPT_TABLE . '
WHERE attempt_time < ' . (time() - (int) $config['ip_login_limit_time']);