code: func daemonSetHistory(
  	apps clientappsv1.AppsV1Interface,
  	namespace, name string) (*appsv1.DaemonSet, []*appsv1.ControllerRevision, error) {
  	ds, err := apps.DaemonSets(namespace).Get(name, metav1.GetOptions{})
  	if err != nil {
  		return nil, nil, fmt.Errorf("failed to retrieve DaemonSet %s: %v", name, err)
  	}
  	selector, err := metav1.LabelSelectorAsSelector(ds.Spec.Selector)
  	if err != nil {
  		return nil, nil, fmt.Errorf("failed to create selector for DaemonSet %s: %v", ds.Name, err)
  	}
  	accessor, err := meta.Accessor(ds)
  	if err != nil {
  		return nil, nil, fmt.Errorf("failed to create accessor for DaemonSet %s: %v", ds.Name, err)
  	}
  	history, err := controlledHistory(apps, ds.Namespace, selector, accessor)
  	if err != nil {
  		return nil, nil, fmt.Errorf("unable to find history controlled by DaemonSet %s: %v", ds.Name, err)
  	}
  	return ds, history, nil
  }
docs: // daemonSetHistory returns the DaemonSet named name in namespace and all ControllerRevisions in its history.