summaryrefslogtreecommitdiff
path: root/sleekxmpp/plugins/xep_0030
diff options
context:
space:
mode:
authorLance Stout <lancestout@gmail.com>2012-03-11 20:43:21 -0700
committerLance Stout <lancestout@gmail.com>2012-03-12 19:32:19 -0700
commita104cd6dae75b4785b3bdc58c944a34a32308b3e (patch)
tree9c89842089e764ea466ddfa6fbcc0e794a84ff00 /sleekxmpp/plugins/xep_0030
parente28728278246b2f73e86969cfdb881d9ef17a51e (diff)
downloadslixmpp-a104cd6dae75b4785b3bdc58c944a34a32308b3e.tar.gz
slixmpp-a104cd6dae75b4785b3bdc58c944a34a32308b3e.tar.bz2
slixmpp-a104cd6dae75b4785b3bdc58c944a34a32308b3e.tar.xz
slixmpp-a104cd6dae75b4785b3bdc58c944a34a32308b3e.zip
Tidy up disco plugin.
Diffstat (limited to 'sleekxmpp/plugins/xep_0030')
-rw-r--r--sleekxmpp/plugins/xep_0030/disco.py4
-rw-r--r--sleekxmpp/plugins/xep_0030/stanza/items.py4
-rw-r--r--sleekxmpp/plugins/xep_0030/static.py5
3 files changed, 5 insertions, 8 deletions
diff --git a/sleekxmpp/plugins/xep_0030/disco.py b/sleekxmpp/plugins/xep_0030/disco.py
index 8171bd01..a5e8fd1c 100644
--- a/sleekxmpp/plugins/xep_0030/disco.py
+++ b/sleekxmpp/plugins/xep_0030/disco.py
@@ -8,13 +8,11 @@
import logging
-import sleekxmpp
from sleekxmpp import Iq
-from sleekxmpp.exceptions import XMPPError, IqError, IqTimeout
from sleekxmpp.plugins import BasePlugin
from sleekxmpp.xmlstream.handler import Callback
from sleekxmpp.xmlstream.matcher import StanzaPath
-from sleekxmpp.xmlstream import register_stanza_plugin, ElementBase, ET, JID
+from sleekxmpp.xmlstream import register_stanza_plugin, JID
from sleekxmpp.plugins.xep_0030 import stanza, DiscoInfo, DiscoItems
from sleekxmpp.plugins.xep_0030 import StaticDisco
diff --git a/sleekxmpp/plugins/xep_0030/stanza/items.py b/sleekxmpp/plugins/xep_0030/stanza/items.py
index c424d90f..512f2336 100644
--- a/sleekxmpp/plugins/xep_0030/stanza/items.py
+++ b/sleekxmpp/plugins/xep_0030/stanza/items.py
@@ -6,7 +6,7 @@
See the file LICENSE for copying permission.
"""
-from sleekxmpp.xmlstream import ElementBase, ET, register_stanza_plugin
+from sleekxmpp.xmlstream import ElementBase, register_stanza_plugin
class DiscoItems(ElementBase):
@@ -140,9 +140,11 @@ class DiscoItem(ElementBase):
interfaces = set(('jid', 'node', 'name'))
def get_node(self):
+ """Return the item's node name or ``None``."""
return self._get_attr('node', None)
def get_name(self):
+ """Return the item's human readable name, or ``None``."""
return self._get_attr('name', None)
diff --git a/sleekxmpp/plugins/xep_0030/static.py b/sleekxmpp/plugins/xep_0030/static.py
index a13364d0..7306461a 100644
--- a/sleekxmpp/plugins/xep_0030/static.py
+++ b/sleekxmpp/plugins/xep_0030/static.py
@@ -9,12 +9,9 @@
import logging
import threading
-import sleekxmpp
from sleekxmpp import Iq
from sleekxmpp.exceptions import XMPPError, IqError, IqTimeout
-from sleekxmpp.xmlstream.handler import Callback
-from sleekxmpp.xmlstream.matcher import StanzaPath
-from sleekxmpp.xmlstream import register_stanza_plugin, ElementBase, ET, JID
+from sleekxmpp.xmlstream import JID
from sleekxmpp.plugins.xep_0030 import DiscoInfo, DiscoItems