diff --git a/PortLookup/plugin.py b/PortLookup/plugin.py
index 770414d..bc5c9d6 100644
--- a/PortLookup/plugin.py
+++ b/PortLookup/plugin.py
@@ -96,14 +96,8 @@ class PortLookup(callbacks.Plugin):
# Remove inline citations (text[1][2][3]), citation needed tags, etc.
text = re.sub('\[.*?]', '', text)
- # List the port notes (tags such as "Official", "TCP", "UDP", etc.)
- # This is every
tag except the 4th one, which is the description parsed
- # above.
- notes = [t.text.strip() for t in tds[:3]+tds[4:] if '?' not in t]
- notes = '; '.join(filter(None, notes))
-
# Remove \n, etc. in fields to prevent output corruption.
- s = utils.str.normalizeWhitespace('%s [%s]' % (ircutils.bold(text), notes))
+ s = utils.str.normalizeWhitespace('%s (%s)' % (ircutils.bold(text), portnum))
results.append(s)
if results:
irc.reply(format('%s: %L', ircutils.bold(ircutils.underline(port)), results))
diff --git a/PortLookup/test.py b/PortLookup/test.py
index 637e840..017ee53 100644
--- a/PortLookup/test.py
+++ b/PortLookup/test.py
@@ -35,7 +35,7 @@ class PortLookupTestCase(PluginTestCase):
plugins = ('PortLookup',)
def testPort(self):
- self.assertRegexp('port 22', 'SSH.*?TCP.*?Official')
+ self.assertRegexp('port 22', 'SSH')
# Some entries in the list are defined as port ranges (i.e.
# 6665-6669); we have to split them manually.
|