lib/storage: remove extra error check (#3396)

This commit is contained in:
匠心零度 2022-11-29 00:07:11 +08:00 committed by Aliaksandr Valialkin
parent 090343ff50
commit fa0ce10275
No known key found for this signature in database
GPG key ID: A72BEC6CD3D0DED1

View file

@ -860,9 +860,6 @@ func testStorageRegisterMetricNames(s *Storage) error {
if err != nil {
return fmt.Errorf("error in SearchMetricNames: %w", err)
}
if err != nil {
return fmt.Errorf("cannot unmarshal metric names: %w", err)
}
if len(metricNames) < metricsPerAdd {
return fmt.Errorf("unexpected number of metricNames returned from SearchMetricNames; got %d; want at least %d", len(metricNames), int(metricsPerAdd))
}