code: protected CmsResource checkContainsSubResources(CmsObject cms, List<CmsResource> folders) throws CmsException {
  
          for (CmsResource folder : folders) {
  
              if (!containsSubResources(cms, folder)) {
                  return folder;
              }
          }
          return null;
      }
docs: Checks whether the publish list contains all sub-resources of a list of folders.<p>
  
  @param cms the current CMS context
  @param folders the folders which should be checked
  @return a folder from the list if one of its sub-resources is not contained in the publish list, otherwise null
  
  @throws CmsException if something goes wrong