Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-14394

DocumentModel.getParentRef() never returns null

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Critical
    • Resolution: Won't Fix
    • Affects Version/s: 5.9.3
    • Fix Version/s: None
    • Component/s: Core

      Description

      The method in DocumentModel getParentRef() is supposed to send null if the document has no parent.

      It actually returns / when called on the root, due to the line:
      Path parentPath = path.removeLastSegments(1);

      When called in a recursive function, this produces an infinite loop.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: