code: func GetReadyReplicaCountForReplicaSets(replicaSets []*apps.ReplicaSet) int32 {
  	totalReadyReplicas := int32(0)
  	for _, rs := range replicaSets {
  		if rs != nil {
  			totalReadyReplicas += rs.Status.ReadyReplicas
  		}
  	}
  	return totalReadyReplicas
  }
docs: // GetReadyReplicaCountForReplicaSets returns the number of ready pods corresponding to the given replica sets.