summaryrefslogtreecommitdiff
path: root/whois.go
diff options
context:
space:
mode:
authorDaniel Langesten <daniel.langest@gmail.com>2015-03-26 11:09:48 +0100
committerDaniel Langesten <daniel.langest@gmail.com>2015-03-26 11:09:48 +0100
commit986a05c215723b9227db20aa11a62e4d924281cb (patch)
tree6401602986bb32827b9defe43faa5e5e93c527f1 /whois.go
parent54f6128240711a93551d85b000766a9b57cc96cf (diff)
added verbose option to enable/disable extra output from the program
Diffstat (limited to 'whois.go')
-rw-r--r--whois.go8
1 files changed, 6 insertions, 2 deletions
diff --git a/whois.go b/whois.go
index 486d978..7e0a50e 100644
--- a/whois.go
+++ b/whois.go
@@ -35,7 +35,9 @@ func main() {
*/
func findIPBlock(domains ...string) (pairs map[string]string, err error) {
- wlogger.Println("Querying for ip-blocks...")
+ if VERBOSE {
+ wlogger.Println("Querying for ip-blocks...")
+ }
if len(domains) == 0 {
return
}
@@ -61,7 +63,9 @@ func findIPBlock(domains ...string) (pairs map[string]string, err error) {
ipb := strings.TrimSpace(content[2])
pairs[ipaddr] = ipb
}
- wlogger.Println("ip-blocks returned")
+ if VERBOSE {
+ wlogger.Println("ip-blocks returned")
+ }
return
}