1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-04-20 07:42:09 +02:00

[ticket/15937] Amend Google reCAPTCHA v3 Migrations

PHPBB3-15937
This commit is contained in:
mrgoldy 2020-03-16 12:05:33 +01:00
parent d35b3b4792
commit feb94b446a

View File

@ -38,24 +38,7 @@ class google_recaptcha_v3 extends \phpbb\db\migration\migration
foreach (\phpbb\captcha\plugins\recaptcha_v3::get_actions() as $action)
{
$data[] = ['config.add', "recaptcha_v3_threshold_{$action}", 0.5];
}
return $data;
}
public function revert_data()
{
$data = [
['config.remove', ['recaptcha_v3_key']],
['config.remove', ['recaptcha_v3_secret']],
['config.remove', ['recaptcha_v3_domain']],
['config.remove', ['recaptcha_v3_method']],
];
foreach (\phpbb\captcha\plugins\recaptcha_v3::get_actions() as $action)
{
$data[] = ['config.remove', "recaptcha_v3_threshold_{$action}"];
$data[] = ['config.add', ["recaptcha_v3_threshold_{$action}", 0.5]];
}
return $data;