Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
asbiin committed Nov 4, 2023
1 parent 1878197 commit d48637d
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions app/Domains/Contact/Dav/Importer.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,13 +93,11 @@ protected function kind(VCard $entry): string

if ($kind === null) {
$kinds = $entry->select('X-ADDRESSBOOKSERVER-KIND');
if ($kinds !== null && count($kinds) > 0) {
if (! empty($kinds)) {
$kind = $kinds[0];
}
}

return $kind === null
? 'individual'
: $kind->getValue();
return optional($kind)->getValue() ?? 'individual';
}
}

0 comments on commit d48637d

Please sign in to comment.