Ref https://github.com/nextcloud/calendar/issues/4811
Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
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'])) {