diff options
-rw-r--r-- | apps/dav/lib/Connector/Sabre/Principal.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/dav/lib/Connector/Sabre/Principal.php b/apps/dav/lib/Connector/Sabre/Principal.php index 7b4b7090832..0a882288314 100644 --- a/apps/dav/lib/Connector/Sabre/Principal.php +++ b/apps/dav/lib/Connector/Sabre/Principal.php @@ -617,8 +617,8 @@ class Principal implements BackendInterface { public function getEmailAddressesOfPrincipal(array $principal): array { $emailAddresses = []; - if (($primaryAddress = $principal['{http://sabredav.org/ns}email-address'])) { - $emailAddresses[] = $primaryAddress; + if (isset($principal['{http://sabredav.org/ns}email-address'])) { + $emailAddresses[] = $principal['{http://sabredav.org/ns}email-address']; } if (isset($principal['{DAV:}alternate-URI-set'])) { |