diff --git a/cmd/crawler/main.go b/cmd/crawler/main.go index 2042d79..c10d6f8 100644 --- a/cmd/crawler/main.go +++ b/cmd/crawler/main.go @@ -73,7 +73,9 @@ func main() { log.Printf("correctly added %d init pubkeys", len(config.InitPubkeys)) } - go printStats(ctx, events, pubkeys) + if config.PrintStats { + go printStats(ctx, events, pubkeys) + } var producers sync.WaitGroup var consumers sync.WaitGroup diff --git a/cmd/sync/main.go b/cmd/sync/main.go index fd64a60..cd890ef 100644 --- a/cmd/sync/main.go +++ b/cmd/sync/main.go @@ -78,7 +78,9 @@ func main() { nostr.KindFollowList, // no need to sync other event kinds } - go printStats(ctx, events, pubkeys) + if config.PrintStats { + go printStats(ctx, events, pubkeys) + } var wg sync.WaitGroup wg.Add(3)