Uploaded image for project: 'CMS'
  1. CMS
  2. CMS-656

Plugin ODF : some classes use Node.isNodeType() on nodes which can be frozen nodes

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 2.9.17
    • 2.9.16
    • Plugins (others)
    • None

      In the ODF plugin, some classes use node.isNodeType() on nodes which can be frozen nodes. In that case, the value returned by isNodeType() is "nt:frozenNode" and the real nodeType is in the jcr:frozenPrimaryType property. Same goes with mixins types, UUID, etc.
      Example in the Container class :

      Node node = (Node) it.next();
      if (node.isNodeType(SchoolPath.NODE_TYPE))
      {
          children.add(new SchoolPath(node));
      }
      ...
      else if (node.isNodeType(TeachingUnitElement.NODE_TYPE))
      {
          children.add(new TeachingUnitElement(node));
      }
      

      If the node iterator is retrieved from a JCR query which returns frozen nodes, the nodes aren't recognized as SchoolPath or any other type, and not processed.

            ngavalda Nicolas Gavalda (Inactive)
            ngavalda Nicolas Gavalda (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: