PortLookup: don't show notes fields marked as ?

This commit is contained in:
James Lu 2017-07-02 11:53:23 -07:00
parent a1826fbc85
commit 75f89cdf6e

View File

@ -99,7 +99,7 @@ class PortLookup(callbacks.Plugin):
# List the port notes (tags such as "Official", "TCP", "UDP", etc.) # List the port notes (tags such as "Official", "TCP", "UDP", etc.)
# This is every <td> tag except the 4th one, which is the description parsed # This is every <td> tag except the 4th one, which is the description parsed
# above. # above.
notes = [t.text.strip() for t in tds[:3]+tds[4:]] notes = [t.text.strip() for t in tds[:3]+tds[4:] if '?' not in t]
notes = '; '.join(filter(None, notes)) notes = '; '.join(filter(None, notes))
# Remove \n, etc. in fields to prevent output corruption. # Remove \n, etc. in fields to prevent output corruption.