summaryrefslogtreecommitdiff
path: root/program
diff options
context:
space:
mode:
authorThomas Bruederli <thomas@roundcube.net>2012-09-17 19:47:33 +0200
committerThomas Bruederli <thomas@roundcube.net>2012-09-17 19:50:00 +0200
commit68a9ff15f2e9982d917ab9c9de5d97e9f000d5bd (patch)
treea1daa0f13bb5df42aa724769edcca9bf6a1908b5 /program
parent3e2a06c6838af0e85f2ebb3e98748afb8f81cdca (diff)
Avoid saving composed FN values with only spaces (shows empty names in listing)
Diffstat (limited to 'program')
-rw-r--r--program/include/rcube_addressbook.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/program/include/rcube_addressbook.php b/program/include/rcube_addressbook.php
index b56b58a65..a74f52149 100644
--- a/program/include/rcube_addressbook.php
+++ b/program/include/rcube_addressbook.php
@@ -482,7 +482,7 @@ abstract class rcube_addressbook
$fn = $contact['name'];
if (!$fn) // default display name composition according to vcard standard
- $fn = join(' ', array_filter(array($contact['prefix'], $contact['firstname'], $contact['middlename'], $contact['surname'], $contact['suffix'])));
+ $fn = trim(join(' ', array_filter(array($contact['prefix'], $contact['firstname'], $contact['middlename'], $contact['surname'], $contact['suffix']))));
// use email address part for name
$email = is_array($contact['email']) ? $contact['email'][0] : $contact['email'];