From 0528b72744b5f40f27eb481fe2295768e735979e Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Wed, 5 Jul 2017 17:55:08 +0200 Subject: [PATCH] * Mail/ActiveDirectory: fix empty identity in mail compose and account not active in AD controled mail-server --- api/src/Mail/Smtp/Ldap.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/api/src/Mail/Smtp/Ldap.php b/api/src/Mail/Smtp/Ldap.php index 2bb5a58d80..ea5b470bb6 100644 --- a/api/src/Mail/Smtp/Ldap.php +++ b/api/src/Mail/Smtp/Ldap.php @@ -429,7 +429,7 @@ class Ldap extends Mail\Smtp if (static::FORWARD_ONLY_ATTR) { // Univention has no extra forward-only attr, but requires primary mail to be in forwards, to have also local delivery - if (static::FORWARD_ONLY_ATTR === static::FORWARD_ATTR) + if (static::FORWARD_ONLY_ATTR === static::FORWARD_ATTR && !static::FORWARD_PREFIX) { $deliveryMode = ''; if ($values[static::FORWARD_ATTR]) @@ -516,6 +516,7 @@ class Ldap extends Mail\Smtp ($k = array_search($userData['mailLocalAddress'],$userData['mailAlternateAddress'])) !== false) { unset($userData['mailAlternateAddress'][$k]); + $userData['mailAlternateAddress'] = array_values($userData['mailAlternateAddress']); } if (static::QUOTA_ATTR && isset($values[static::QUOTA_ATTR]))