From 19ff7f759967022f7a22dcdb248e6e636db67086 Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Tue, 28 Dec 2010 23:34:56 +0100 Subject: [PATCH] Only set the encoding parameter for binary data in vCards, if data is not empty (Bug #9413). --- turba/docs/CHANGES | 2 ++ turba/lib/Driver.php | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) 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']; } -- 2.11.0