diff --git a/pkg/output/output.go b/pkg/output/output.go index 190faad..a5bdbe7 100644 --- a/pkg/output/output.go +++ b/pkg/output/output.go @@ -14,7 +14,7 @@ type JSONResult struct { } func WriteURLs(writer io.Writer, results <-chan string, blacklistMap map[string]struct{}, RemoveParameters bool) error { - lastURL := make(map[string]bool) + lastURL := make(map[string]struct{}) for result := range results { buf := bytebufferpool.Get() if len(blacklistMap) != 0 { @@ -36,10 +36,10 @@ func WriteURLs(writer io.Writer, results <-chan string, blacklistMap map[string] if err != nil { continue } - if lastURL[u.Host+u.Path] { + if _, ok := lastURL[u.Host+u.Path]; ok { continue } else { - lastURL[u.Host+u.Path] = true ; + lastURL[u.Host+u.Path] = struct{}{} ; } } diff --git a/pkg/providers/providers.go b/pkg/providers/providers.go index f3d1471..4324413 100644 --- a/pkg/providers/providers.go +++ b/pkg/providers/providers.go @@ -5,7 +5,7 @@ import ( "github.com/valyala/fasthttp" ) -const Version = `2.0.8` +const Version = `2.0.9` // Provider is a generic interface for all archive fetchers type Provider interface {