File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
ReCaptchaWebapiRest/Plugin Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -71,15 +71,17 @@ public function __construct(
7171 * Validate ReCaptcha if needed.
7272 *
7373 * @param RequestValidator $subject
74+ * @param callable $proceed
7475 * @throws WebapiException
7576 * @return void
7677 *
7778 * @SuppressWarnings(PHPMD.UnusedFormalParameter)
7879 */
79- public function afterValidate (RequestValidator $ subject ): void
80+ public function aroundValidate (RequestValidator $ subject, callable $ proceed ): void
8081 {
81- $ route = $ this ->restRouter ->match ($ this ->request );
82- /** @var Endpoint $endpoint */
82+ $ request = clone $ this ->request ;
83+ $ proceed ();
84+ $ route = $ this ->restRouter ->match ($ request );
8385 $ endpoint = $ this ->endpointFactory ->create ([
8486 'class ' => $ route ->getServiceClass (),
8587 'method ' => $ route ->getServiceMethod (),
You can’t perform that action at this time.
0 commit comments