ok not has
This commit is contained in:
parent
1312da4c0c
commit
5183814775
|
@ -154,7 +154,7 @@ func (m *MetricVec) DeleteLabelValues(lvs ...string) bool {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
if _, has := m.children[h]; !has {
|
if _, ok := m.children[h]; !ok {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
delete(m.children, h)
|
delete(m.children, h)
|
||||||
|
@ -179,7 +179,7 @@ func (m *MetricVec) Delete(labels Labels) bool {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
if _, has := m.children[h]; !has {
|
if _, ok := m.children[h]; !ok {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
delete(m.children, h)
|
delete(m.children, h)
|
||||||
|
|
Loading…
Reference in New Issue