[telepathy-gabble/telepathy-gabble-0.8] gabbletest.py: Fix make_presence() to be able to send a presence stanza with an empty <photo/>

Alban Crequy alban.crequy at collabora.co.uk
Thu Oct 8 03:42:13 PDT 2009


---
 tests/twisted/gabbletest.py |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/tests/twisted/gabbletest.py b/tests/twisted/gabbletest.py
index 13a9989..ca52ec7 100644
--- a/tests/twisted/gabbletest.py
+++ b/tests/twisted/gabbletest.py
@@ -507,8 +507,7 @@ def make_presence(_from, to='test at localhost', type=None, show=None,
     # <x xmlns="vcard-temp:x:update"><photo>4a1...</photo></x>
     if photo is not None:
         x = presence.addElement((ns.VCARD_TEMP_UPDATE, 'x'))
-        if photo != "":
-            x.addElement('photo').addContent(photo)
+        x.addElement('photo').addContent(photo)
 
     return presence
 
-- 
1.5.6.5




More information about the telepathy-commits mailing list