summaryrefslogtreecommitdiff
path: root/sleekxmpp/plugins/xep_0030.py
diff options
context:
space:
mode:
Diffstat (limited to 'sleekxmpp/plugins/xep_0030.py')
-rw-r--r--sleekxmpp/plugins/xep_0030.py11
1 files changed, 7 insertions, 4 deletions
diff --git a/sleekxmpp/plugins/xep_0030.py b/sleekxmpp/plugins/xep_0030.py
index 6a31d243..9fcc8b17 100644
--- a/sleekxmpp/plugins/xep_0030.py
+++ b/sleekxmpp/plugins/xep_0030.py
@@ -138,6 +138,9 @@ class DiscoNode(object):
self.info = DiscoInfo()
self.items = DiscoItems()
+ self.info['node'] = name
+ self.items['node'] = name
+
# This is a bit like poor man's inheritance, but
# to simplify adding information to the node we
# map node functions to either the info or items
@@ -290,19 +293,19 @@ class xep_0030(base.base_plugin):
# Older interface methods for backwards compatibility
- def getInfo(self, jid, node=''):
+ def getInfo(self, jid, node='', dfrom=None):
iq = self.xmpp.Iq()
iq['type'] = 'get'
iq['to'] = jid
- iq['from'] = self.xmpp.fulljid
+ iq['from'] = dfrom
iq['disco_info']['node'] = node
iq.send()
- def getItems(self, jid, node=''):
+ def getItems(self, jid, node='', dfrom=None):
iq = self.xmpp.Iq()
iq['type'] = 'get'
iq['to'] = jid
- iq['from'] = self.xmpp.fulljid
+ iq['from'] = dfrom
iq['disco_items']['node'] = node
iq.send()