From 67775fb8bdd806517864354564cb30aa0a6b4d66 Mon Sep 17 00:00:00 2001 From: Lance Stout Date: Thu, 16 Dec 2010 15:38:00 -0500 Subject: Use boundjid in plugins instead of the deprecated accessors. Originally contributed by skinkie, with a few modifications. --- sleekxmpp/plugins/xep_0045.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sleekxmpp/plugins/xep_0045.py') diff --git a/sleekxmpp/plugins/xep_0045.py b/sleekxmpp/plugins/xep_0045.py index db41cdb3..e7f8c7ec 100644 --- a/sleekxmpp/plugins/xep_0045.py +++ b/sleekxmpp/plugins/xep_0045.py @@ -271,7 +271,7 @@ class xep_0045(base.base_plugin): def invite(self, room, jid, reason=''): """ Invite a jid to a room.""" msg = self.xmpp.makeMessage(room) - msg['from'] = self.xmpp.jid + msg['from'] = self.xmpp.boundjid.bare x = ET.Element('{http://jabber.org/protocol/muc#user}x') invite = ET.Element('{http://jabber.org/protocol/muc#user}invite', {'to': jid}) if reason: @@ -294,7 +294,7 @@ class xep_0045(base.base_plugin): def getRoomConfig(self, room): iq = self.xmpp.makeIqGet('http://jabber.org/protocol/muc#owner') iq['to'] = room - iq['from'] = self.xmpp.jid + iq['from'] = self.xmpp.boundjid.bare result = iq.send() if result is None or result['type'] != 'result': raise ValueError @@ -316,7 +316,7 @@ class xep_0045(base.base_plugin): query.append(x) iq = self.xmpp.makeIqSet(query) iq['to'] = room - iq['from'] = self.xmpp.jid + iq['from'] = self.xmpp.boundjid.bare iq.send() def getJoinedRooms(self): -- cgit v1.2.3