# HG changeset patch # User Goffi # Date 1546545068 -3600 # Node ID 1f5b0262335512f8a28e99fab19f7f0a7a4829a9 # Parent 1797671827b996b1c53ae4310e52f1a2e6460fa2 core (xmpp): implemented human friendly __unicode__ for client diff -r 1797671827b9 -r 1f5b02623355 sat/core/xmpp.py --- a/sat/core/xmpp.py Thu Jan 03 20:49:21 2019 +0100 +++ b/sat/core/xmpp.py Thu Jan 03 20:51:08 2019 +0100 @@ -69,6 +69,12 @@ self.actions = {} # used to keep track of actions for retrieval (key = action_id) self.encryption = encryption.EncryptionHandler(self) + def __unicode__(self): + return u"Client instance for profile {profile}".format(profile=self.profile) + + def __str__(self): + return self.__unicode__.encode('utf-8') + ## initialisation ## @defer.inlineCallbacks