concurrency: use goroutine(too fast)

This commit is contained in:
vinchent 2024-09-18 09:26:39 +02:00
parent 93d9a14858
commit cb8e6d23f3

View File

@ -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
}