From 16fcb03340cc2352af69fca7875be91d8b82e149 Mon Sep 17 00:00:00 2001 From: Alexander Vorwerk Date: Fri, 29 Jul 2022 02:19:27 +0200 Subject: [PATCH] Run ConfirmEditTriggersCaptchaHook under correct name also fix the var name to match the one in the interface Bug: T303433 Follow-Up: If48689fe068aa3ec56e51e01b84cf25c63bcbf0b Change-Id: Ie47b98d08cba5217f8661aa44f6331447575d7ae --- includes/Hooks/ConfirmEditTriggersCaptchaHook.php | 2 +- includes/Hooks/HookRunner.php | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/Hooks/ConfirmEditTriggersCaptchaHook.php b/includes/Hooks/ConfirmEditTriggersCaptchaHook.php index 14632dca4..2c171c9a1 100644 --- a/includes/Hooks/ConfirmEditTriggersCaptchaHook.php +++ b/includes/Hooks/ConfirmEditTriggersCaptchaHook.php @@ -24,7 +24,7 @@ use MediaWiki\Page\PageIdentity; /** * This is a hook handler interface, see docs/Hooks.md in core. - * Use the hook name "ConfirmEditTriggersCaptchaHook" to register handlers implementing this interface. + * Use the hook name "ConfirmEditTriggersCaptcha" to register handlers implementing this interface. * * @author Zabe * @stable to implement diff --git a/includes/Hooks/HookRunner.php b/includes/Hooks/HookRunner.php index fc29e7914..72694d6b1 100644 --- a/includes/Hooks/HookRunner.php +++ b/includes/Hooks/HookRunner.php @@ -46,14 +46,14 @@ class HookRunner implements */ public function onConfirmEditTriggersCaptcha( string $action, - ?PageIdentity $title, + ?PageIdentity $page, bool &$result ) { $this->hookContainer->run( - 'ConfirmEditTriggersCaptchaHook', + 'ConfirmEditTriggersCaptcha', [ $action, - $title, + $page, &$result ] );