Skip to content

Commit

Permalink
Merge pull request #123 from nrwiersma/reliable-index-write
Browse files Browse the repository at this point in the history
fix: consistently write state
  • Loading branch information
danielfoehrKn authored May 9, 2024
2 parents fe26432 + 199e2fd commit e96e19e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/search.go
Original file line number Diff line number Diff line change
Expand Up @@ -199,13 +199,13 @@ func DoSearch(stores []store.KubeconfigStore, config *types.Config, stateDir str
}
}

// reading from this store is finished, decrease wait counter
wgResultChannel.Done()

// write store index file now that the path discovery is complete
if len(localContextToPathMapping) > 0 {
writeIndex(store, &index, localContextToPathMapping, localContextToTagsMapping)
}

// reading from this store is finished, decrease wait counter
wgResultChannel.Done()
}(kubeconfigStore, c, *searchIndex)
}

Expand Down

0 comments on commit e96e19e

Please sign in to comment.