diff options
author | Krzysztof Klinikowski <kkszysiu@gmail.com> | 2010-01-01 11:44:41 +0100 |
---|---|---|
committer | Krzysztof Klinikowski <kkszysiu@gmail.com> | 2010-01-01 11:44:41 +0100 |
commit | 2b93619be566585796ac7ac337cd903060b71c3b (patch) | |
tree | 00d5111ee146d3854b60c3657e36e457172e7c6e | |
parent | db119f7426e06a7fefebeecff831af56375fa33e (diff) |
Big change. Now messages even to older clients should be good.
-rw-r--r-- | gadu/channel/text.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gadu/channel/text.py b/gadu/channel/text.py index b781d6f..0f4c2fa 100644 --- a/gadu/channel/text.py +++ b/gadu/channel/text.py @@ -46,7 +46,8 @@ class GaduTextChannel(telepathy.server.ChannelTypeText): def Send(self, message_type, text): if message_type == telepathy.CHANNEL_TEXT_MESSAGE_TYPE_NORMAL: logger.info("Sending message : %s" % unicode(text)) - self.conn.gadu_client.sendTo(int(self.contact.uin), str(text), str(text)) + msg = text.encode('windows-1250') + self.conn.gadu_client.sendTo(int(self.contact.uin), str(text), str(msg)) else: raise telepathy.NotImplemented("Unhandled message type") self.Sent(int(time.time()), message_type, text) |