public function LdapHelpRedirect::redirectUrl in Lightweight Directory Access Protocol (LDAP) 8.3
Same name and namespace in other branches
- 8.4 ldap_authentication/src/Controller/LdapHelpRedirect.php \Drupal\ldap_authentication\Controller\LdapHelpRedirect::redirectUrl()
Redirect.
Return value
\Drupal\Core\Routing\TrustedRedirectResponse Redirect response.
1 string reference to 'LdapHelpRedirect::redirectUrl'
- ldap_authentication.routing.yml in ldap_authentication/
ldap_authentication.routing.yml - ldap_authentication/ldap_authentication.routing.yml
File
- ldap_authentication/
src/ Controller/ LdapHelpRedirect.php, line 22
Class
- LdapHelpRedirect
- Class LdapHelpRedirect.
Namespace
Drupal\ldap_authentication\ControllerCode
public function redirectUrl() : TrustedRedirectResponse {
$url = $this
->config('ldap_authentication.settings')
->get('ldapUserHelpLinkUrl');
$cacheable_metadata = new CacheableMetadata();
$cacheable_metadata
->setCacheMaxAge(0);
$response = new TrustedRedirectResponse($url);
$response
->addCacheableDependency($cacheable_metadata);
return $response;
}