[telepathy-mission-control/master] mctest: get the special case for non-persistent avatars right
Simon McVittie
simon.mcvittie at collabora.co.uk
Wed Jun 3 03:44:21 PDT 2009
---
test/twisted/mctest.py | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/test/twisted/mctest.py b/test/twisted/mctest.py
index f54e158..50c90e0 100644
--- a/test/twisted/mctest.py
+++ b/test/twisted/mctest.py
@@ -271,12 +271,11 @@ class SimulatedConnection(object):
def GetKnownAvatarTokens(self, e):
ret = dbus.Dictionary(signature='us')
- # the user has an avatar already; nobody else does
+ # the user has an avatar already, if they persist; nobody else does
if self.self_handle in e.args[0]:
- if self.avatar is None:
- ret[self.self_handle] = ''
- else:
+ if self.avatar is not None:
# we just stringify the avatar as the token
+ # (also, empty avatar => no avatar => empty token)
ret[self.self_handle] = str(self.avatar[0])
self.q.dbus_return(e.message, ret, signature='a{us}')
--
1.5.6.5
More information about the telepathy-commits
mailing list