fixed mail check

This commit is contained in:
Roland Gruber 2016-11-12 09:51:08 +01:00
parent 4373c1b040
commit 213c65d115
1 changed files with 1 additions and 1 deletions

View File

@ -281,7 +281,7 @@ class inetLocalMailRecipient extends baseModule {
// check if address has correct format // check if address has correct format
if (get_preg($_POST['localAdr'], 'mailLocalAddress')) { if (get_preg($_POST['localAdr'], 'mailLocalAddress')) {
// check if new address is not already in database // check if new address is not already in database
$data = searchLDAPByAttribute('mailLocalAddress', $_POST['localAdr'], 'inetLocalMailRecipient', array('dn'), array('user')); $data = searchLDAPByAttribute('mailLocalAddress', $_POST['localAdr'], 'inetLocalMailRecipient', array('dn'), array($this->get_scope()));
if (sizeof($data) > 0) { if (sizeof($data) > 0) {
$errors[] = array('WARN', _('This mail address is already in use:') . " " . $_POST['localAdr'], $data[0]['dn']); $errors[] = array('WARN', _('This mail address is already in use:') . " " . $_POST['localAdr'], $data[0]['dn']);
} }