github-vet / github-vet/rangeloop-pointer-findings
uvalib/virgo4-pool-solr-ws: cmd/virgo-mappings.go; 17 LoC
- Dominant language
- No language data
- Stars
- 0
- Forks
- 0
- PR merge metrics
- PR metrics pending
Description
Found a possible issue in [uvalib/virgo4-pool-solr-ws](https://www.github.com/uvalib/virgo4-pool-solr-ws) at [cmd/virgo-mappings.go](https://github.com/uvalib/virgo4-pool-solr-ws/blob/b7594197b5565acdfe9e1fdcf79a9c718fd73831/cmd/virgo-mappings.go#L510-L526)
Below is the message reported by the analyzer for this snippet of code. Beware that the analyzer only reports the first issue it finds, so please do not limit your consideration to the contents of the below message.
> reference to val is reassigned at line 521
[Click here to see the code in its original context.](https://github.com/uvalib/virgo4-pool-solr-ws/blob/b7594197b5565acdfe9e1fdcf79a9c718fd73831/cmd/virgo-mappings.go#L510-L526)
Click here to show the 17 line(s) of Go which triggered the analyzer.
```go
for key, val := range solrFacets {
if s.solr.req.meta.requestFacets[key] == nil {
continue
}
switch s.solr.req.meta.requestFacets[key].config.Type {
case "component":
xid := s.solr.req.meta.requestFacets[key].config.XID
if componentQueries[xid] == nil {
componentQueries[xid] = make(map[string]*solrResponseFacet)
}
componentQueries[xid][key] = &val
default:
mergedFacets[key] = val
}
}
```
Leave a reaction on this issue to contribute to the project by classifying this instance as a **Bug** :-1:, **Mitigated** :+1:, or **Desirable Behavior** :rocket:
See the descriptions of the classifications [here](https://github.com/github-vet/rangeclosure-findings#how-can-i-help) for more information.
commit ID: b7594197b5565acdfe9e1fdcf79a9c718fd73831
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.