diff --git a/lib/storage/storage.go b/lib/storage/storage.go index bb9cb562ce..ee7cf33bfd 100644 --- a/lib/storage/storage.go +++ b/lib/storage/storage.go @@ -1038,7 +1038,7 @@ func (s *Storage) add(rows []rawRow, mrs []MetricRow, precisionBits uint8) ([]ra if err := s.tb.AddRows(rows); err != nil { lastError = fmt.Errorf("cannot add rows to table: %s", err) } - if err := s.updatePerDateData(rows, lastError); err != nil lastError == nil { + if err := s.updatePerDateData(rows, lastError); err != nil && lastError == nil { lastError = fmt.Errorf("cannot update per-date data: %s", err) } if lastError != nil {