From 0f8cca049f668711e7b44f6d8aca9488b0011265 Mon Sep 17 00:00:00 2001 From: Patrizio Bekerle <patrizio@bekerle.com> Date: Thu, 20 Jan 2022 12:56:27 +0100 Subject: [PATCH] Fix missing email addresses --- src/Service/LDAPApi.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Service/LDAPApi.php b/src/Service/LDAPApi.php index 8b68ca6..aaca735 100644 --- a/src/Service/LDAPApi.php +++ b/src/Service/LDAPApi.php @@ -260,7 +260,7 @@ class LDAPApi implements LoggerAwareInterface, ServiceSubscriberInterface $person->setFamilyName($user->getFirstAttribute($this->familyNameAttributeName)); if ($this->emailAttributeName !== '') { - $person->setEmail($user->getFirstAttribute($this->emailAttributeName)); + $person->setEmail($user->getFirstAttribute($this->emailAttributeName) ?? ''); } $birthDateString = $this->birthdayAttributeName !== '' ? -- GitLab