diff --git a/application/forms/Config/Resource/LdapResourceForm.php b/application/forms/Config/Resource/LdapResourceForm.php index 9ae935d73..7ffccdc1f 100644 --- a/application/forms/Config/Resource/LdapResourceForm.php +++ b/application/forms/Config/Resource/LdapResourceForm.php @@ -48,38 +48,7 @@ class LdapResourceForm extends Form 'The hostname or address of the LDAP server to use for authentication.' . ' You can also provide multiple hosts separated by a space' ), - 'value' => 'localhost', - 'validators' => array( - array( - 'Callback', - false, - array( - 'callback' => function ($v) { - $withoutScheme = $withScheme = false; - foreach (explode(' ', $v) as $uri) { - if (preg_match('~^(?getScheme()) { - $withScheme = true; - } else { - $withoutScheme = true; - } - } - - return $withScheme ^ $withoutScheme; - }, - 'messages' => array( - 'callbackValue' => $this->translate( - 'A protocol scheme such as ldap:// or ldaps:// is mandatory for URIs with a given' - . ' port and for all other URIs as well once a scheme is given for a single one.' - ) - ) - ) - ) - ) + 'value' => 'localhost' ) ); $this->addElement(