diff options
author | Lance Stout <lancestout@gmail.com> | 2010-12-16 15:38:00 -0500 |
---|---|---|
committer | Lance Stout <lancestout@gmail.com> | 2010-12-16 15:38:00 -0500 |
commit | 67775fb8bdd806517864354564cb30aa0a6b4d66 (patch) | |
tree | 2f8d09e9e30797e7a3ceca03a98f62563e09189b /sleekxmpp/plugins/xep_0045.py | |
parent | e81683beeee5e7e03e05ad10320ebd1adb30269f (diff) | |
download | slixmpp-67775fb8bdd806517864354564cb30aa0a6b4d66.tar.gz slixmpp-67775fb8bdd806517864354564cb30aa0a6b4d66.tar.bz2 slixmpp-67775fb8bdd806517864354564cb30aa0a6b4d66.tar.xz slixmpp-67775fb8bdd806517864354564cb30aa0a6b4d66.zip |
Use boundjid in plugins instead of the deprecated accessors.
Originally contributed by skinkie, with a few modifications.
Diffstat (limited to 'sleekxmpp/plugins/xep_0045.py')
-rw-r--r-- | sleekxmpp/plugins/xep_0045.py | 6 |
1 files changed, 3 insertions, 3 deletions
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): |