concurrency: use goroutine(too fast)
This commit is contained in:
parent
93d9a14858
commit
cb8e6d23f3
@ -6,7 +6,9 @@ func CheckWebsites(wc WebsiteChecker, urls []string) map[string]bool {
|
||||
results := make(map[string]bool)
|
||||
|
||||
for _, url := range urls {
|
||||
go func() {
|
||||
results[url] = wc(url)
|
||||
}()
|
||||
}
|
||||
return results
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user