mirror of
https://github.com/roundcube/roundcubemail.git
synced 2026-03-07 16:46:47 +01:00
Fix importing contacts with no email address (#8227)
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
- Password: Verify current password with IMAP (#8142)
|
||||
- Password: Improve handling errors on executed commands (#8200)
|
||||
- Fix locked SQLite database for the CLI tools (#8035)
|
||||
- Fix importing contacts with no email address (#8227)
|
||||
|
||||
## Release 1.5.0
|
||||
|
||||
|
||||
@@ -196,8 +196,11 @@ class rcmail_action_contacts_import extends rcmail_action_contacts_index
|
||||
}
|
||||
|
||||
// We're using UTF8 internally
|
||||
$email = $vcard->email[0];
|
||||
$email = rcube_utils::idn_to_utf8($email);
|
||||
$email = null;
|
||||
if (isset($vcard->email[0])) {
|
||||
$email = $vcard->email[0];
|
||||
$email = rcube_utils::idn_to_utf8($email);
|
||||
}
|
||||
|
||||
if (!$replace) {
|
||||
$existing = null;
|
||||
|
||||
@@ -809,6 +809,8 @@ class rcube_contacts extends rcube_addressbook
|
||||
// save all e-mails in the database column
|
||||
if (!empty($vcard->email)) {
|
||||
$out['email'] = implode(self::SEPARATOR, $vcard->email);
|
||||
} else {
|
||||
$out['email'] = isset($save_data['email']) ? $save_data['email'] : '';
|
||||
}
|
||||
|
||||
// join words for fulltext search
|
||||
|
||||
Reference in New Issue
Block a user