go-graphite / carbonapi

Functions prefixed with Get should return a value RVV-A0006
Anti-pattern
Major
6 months ago2 years old
function 'getPercentages' seems to be a getter but it does not return any result
 76// indices in series starting at the length of totalSeries.Values. If the number of values
 77// in totalSeries is greater than the number of values in series, then math.NaN() needs
 78// to be appended to series until its values have the same length as totalSeries.Values
 79func getPercentages(series, totalSeries *types.MetricData) { 80	// If there are more series values than totalSeries values, set series value to math.NaN() for those indices
 81	if len(series.Values) > len(totalSeries.Values) {
 82		for i := 0; i < len(totalSeries.Values); i++ {