mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-26 02:29:20 +03:00
Fix namespace and FN default
This commit is contained in:
parent
46cfa9ffa1
commit
cc25129a5e
1 changed files with 3 additions and 2 deletions
|
|
@ -1,10 +1,9 @@
|
|||
<?php
|
||||
use RainLoop\Providers\AddressBook\Classes\Contact;
|
||||
use Sabre\VObject\Component\VCard;
|
||||
|
||||
class NextcloudAddressBook implements \RainLoop\Providers\AddressBook\AddressBookInterface
|
||||
{
|
||||
use Rainloop\Providers\AddressBook\CardDAV;
|
||||
use RainLoop\Providers\AddressBook\CardDAV;
|
||||
private const URI = 'webmail';
|
||||
private $contactsManager;
|
||||
private $key;
|
||||
|
|
@ -126,6 +125,8 @@ class NextcloudAddressBook implements \RainLoop\Providers\AddressBook\AddressBoo
|
|||
$properties['EMAIL'] = \trim($sEmail);
|
||||
if ('' !== \trim($oEmail->GetDisplayName())) {
|
||||
$properties['FN'] = $oEmail->GetDisplayName();
|
||||
} else {
|
||||
$properties['FN'] = \trim($sEmail);
|
||||
}
|
||||
$this->contactsManager->createOrUpdate($properties, $this->key);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue