code: def is_folderish(brain_or_object):
      
      if hasattr(brain_or_object, "is_folderish"):
          if callable(brain_or_object.is_folderish):
              return brain_or_object.is_folderish()
          return brain_or_object.is_folderish
      return IFolderish.providedBy(get_object(brain_or_object))
docs: Checks if the passed in object is folderish
  
      :param brain_or_object: A single catalog brain or content object
      :type brain_or_object: ATContentType/DexterityContentType/CatalogBrain
      :returns: True if the object is folderish
      :rtype: bool