code: func validateVirtualMachineFolder(folder *object.Folder) (*object.Folder, error) {
  	ft, err := FindType(folder)
  	if err != nil {
  		return nil, err
  	}
  	if ft != VSphereFolderTypeVM {
  		return nil, fmt.Errorf("%q is not a VM folder", folder.InventoryPath)
  	}
  	log.Printf("[DEBUG] Folder located: %q", folder.InventoryPath)
  	return folder, nil
  }
docs: // validateVirtualMachineFolder checks to make sure the folder is a VM folder,
  // and returns it if it is, or an error if it isn't.