code: func filterList(rels []*release.Release) []*release.Release {
  	idx := map[string]int32{}
  
  	for _, r := range rels {
  		name, version := r.GetName(), r.GetVersion()
  		if max, ok := idx[name]; ok {
  			// check if we have a greater version already
  			if max > version {
  				continue
  			}
  		}
  		idx[name] = version
  	}
  
  	uniq := make([]*release.Release, 0, len(idx))
  	for _, r := range rels {
  		if idx[r.GetName()] == r.GetVersion() {
  			uniq = append(uniq, r)
  		}
  	}
  	return uniq
  }
docs: // filterList returns a list scrubbed of old releases.