|
|
@@ -189,7 +189,7 @@ func writePromExpVar(w io.Writer, prefix string, kv expvar.KeyValue) {
|
|
|
// IntMap uses expvar.Map on the inside, which presorts
|
|
|
// keys. The output ordering is deterministic.
|
|
|
v.Do(func(kv expvar.KeyValue) {
|
|
|
- fmt.Fprintf(w, "%s{%s=%q} %v\n", name, v.Label, kv.Key, kv.Value)
|
|
|
+ fmt.Fprintf(w, "%s{%s=%q} %v\n", name, cmpx.Or(v.Label, "label"), kv.Key, kv.Value)
|
|
|
})
|
|
|
case *expvar.Map:
|
|
|
if label != "" && typ != "" {
|