func updateActiveTsFromResponse(bucket string, activeTs *protobuf.TsVbuuid, res *protobuf.TopicResponse) *protobuf.TsVbuuid { activeTsList := res.GetActiveTimestamps() for _, ts := range activeTsList { if ts != nil && !ts.IsEmpty() && ts.GetBucket() == bucket { if activeTs == nil { activeTs = ts.Clone() } else { activeTs = activeTs.Union(ts) } } } return activeTs }