From: Jan Schneider Date: Tue, 28 Dec 2010 22:34:56 +0000 (+0100) Subject: Only set the encoding parameter for binary data in vCards, if data is not empty ... X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=19ff7f759967022f7a22dcdb248e6e636db67086;p=horde.git Only set the encoding parameter for binary data in vCards, if data is not empty (Bug #9413). --- diff --git a/turba/docs/CHANGES b/turba/docs/CHANGES index 27309c9d9..b8bd31c15 100644 --- a/turba/docs/CHANGES +++ b/turba/docs/CHANGES @@ -16,6 +16,8 @@ v3.0-git v2.3.6-cvs ---------- +[jan] Only set the encoding parameter for binary data in vCards, if data is not + empty (Bug #9413). [jan] Fix searching for fields matching an email address if using 'emails' attribute instead of 'email' (Bug #9472). [jan] Use personal address books first if determining the default one (Valentin diff --git a/turba/lib/Driver.php b/turba/lib/Driver.php index 67486d867..a6d619c44 100644 --- a/turba/lib/Driver.php +++ b/turba/lib/Driver.php @@ -1593,7 +1593,10 @@ class Turba_Driver implements Countable case 'photo': case 'logo': $name = Horde_String::upper($key); - $params = array('ENCODING' => 'b'); + $params = array(); + if (strlen($val)) { + $params['ENCODING'] = 'b'; + } if (isset($hash[$key . 'type'])) { $params['TYPE'] = $hash[$key . 'type']; }