Skip to content

Commit

Permalink
chore: unnecessary guard around call to delete
Browse files Browse the repository at this point in the history
Signed-off-by: guoguangwu <guoguangwu@magic-shield.com>
  • Loading branch information
testwill committed Oct 17, 2023
1 parent acd3f0a commit 44e6c5b
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/prom/prom_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,7 @@ func TestMetrics_Observe(t *testing.T) {
name, _ := p.Help()
nameStr := string(name)

if _, ok := want[nameStr]; ok {
delete(want, nameStr)
}
delete(want, nameStr)
}

if len(want) > 0 {
Expand Down

0 comments on commit 44e6c5b

Please sign in to comment.