mirror of
https://github.com/ossf/scorecard.git
synced 2024-09-17 11:57:12 +03:00
Fix bug in shardNum calculation (#910)
Co-authored-by: Azeem Shaikh <azeems@google.com>
This commit is contained in:
parent
2d65ab4f0c
commit
1c7c1e3c31
@ -75,6 +75,9 @@ func publishToRepoRequestTopic(ctx context.Context, iter data.Iterator, datetime
|
||||
if err := topicPublisher.Publish(&request); err != nil {
|
||||
return shardNum, fmt.Errorf("error running topicPublisher.Publish: %w", err)
|
||||
}
|
||||
} else {
|
||||
// shardNum incremented for an empty shard, decrement.
|
||||
shardNum--
|
||||
}
|
||||
|
||||
if err := topicPublisher.Close(); err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user