*/ public function getConfig(?CaptchaServiceInterface $service): array { $config = [ 'configured' => false, 'type' => 'v2', 'siteKey' => '', 'scriptUrl' => '', 'size' => 'normal' ]; if ($service && $service->isConfigured()) { $recaptchaConfig = $service->getFrontendConfig( $service->getType(), $service->getSiteKey() ); $recaptchaConfig['configured'] = true; return $recaptchaConfig; } return $config; } }