mirror of
https://github.com/C24Be/AS_Network_List.git
synced 2026-01-24 23:26:38 +03:00
whois
This commit is contained in:
@@ -29,6 +29,9 @@ def whois_query(query, get_field="netname", get_org=False):
|
|||||||
if line.startswith(get_field + ':'):
|
if line.startswith(get_field + ':'):
|
||||||
basic_name = line.split(':')[1].strip()
|
basic_name = line.split(':')[1].strip()
|
||||||
|
|
||||||
|
if org_name is None:
|
||||||
|
org_name = 'No org name found'
|
||||||
|
|
||||||
if get_org is True:
|
if get_org is True:
|
||||||
return basic_name + ' (' + org_name + ')'
|
return basic_name + ' (' + org_name + ')'
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user