mirror of
https://github.com/go-kit/kit.git
synced 2025-07-15 01:04:44 +02:00
Fix unnecessary calls to Printf
This commit is contained in:
committed by
Mark Sagi-Kazar
parent
801da84a68
commit
abd72ba989
12
.deepsource.toml
Normal file
12
.deepsource.toml
Normal file
@ -0,0 +1,12 @@
|
||||
version = 1
|
||||
|
||||
test_patterns = ["**/*_test.go"]
|
||||
|
||||
exclude_patterns = ["examples/**"]
|
||||
|
||||
[[analyzers]]
|
||||
name = "go"
|
||||
enabled = true
|
||||
|
||||
[analyzers.meta]
|
||||
import_paths = ["github.com/go-kit/kit"]
|
@ -182,7 +182,7 @@ func (h *Histogram) LabelValues() []string {
|
||||
func (h *Histogram) Print(w io.Writer) {
|
||||
h.h.RLock()
|
||||
defer h.h.RUnlock()
|
||||
fmt.Fprintf(w, h.h.String())
|
||||
fmt.Fprint(w, h.h.String())
|
||||
}
|
||||
|
||||
// safeHistogram exists as gohistogram.Histogram is not goroutine-safe.
|
||||
|
Reference in New Issue
Block a user