Skip to content

Commit

Permalink
Merge pull request #680 from anarcat/ip_ASNs
Browse files Browse the repository at this point in the history
leave the AS number in display
  • Loading branch information
Elad Alfassa committed Dec 19, 2014
2 parents 599fb13 + d06549e commit 000b990
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions willie/modules/ip.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def _find_geoip_db(bot):

@commands('iplookup', 'ip')
@example('.ip 8.8.8.8',
r'[IP/Host Lookup] Hostname: google-public-dns-a.google.com | Location: United States | Region: CA | ISP: Google Inc.',
r'[IP/Host Lookup] Hostname: google-public-dns-a.google.com | Location: United States | Region: CA | ISP: AS15169 Google Inc.',
re=True,
ignore='Downloading GeoIP database, please wait...')
def ip(bot, trigger):
Expand Down Expand Up @@ -125,8 +125,6 @@ def ip(bot, trigger):
response += " | Region: %s" % region

isp = gi_org.org_by_name(query)
if isp is not None:
isp = re.sub('^AS\d+ ', '', isp)
response += " | ISP: %s" % isp
bot.say(response)

Expand Down

0 comments on commit 000b990

Please sign in to comment.