Uploaded image for project: 'Fluid Infusion'
  1. Fluid Infusion
  2. FLUID-3729

Further recurrence of "pen.root is undefined" error within changeApplier

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.2
    • 1.3
    • Data Binder
    • None

    Description

      Whilst this was thought fixed a while ago, there is another code path via which it can be triggered. See http://issues.collectionspace.org/browse/CSPACE-2795 - the relevant case is where model is, say:

      fields:

      { lenders: [] }

      and we receive a change request for "fields.lenders.0.lender". Currently the 2nd branch of fluid.model.applyChangeRequest attempts pen.root[pen.last] = request.value. However, pen contains

      { last: "lender", root: undefined }

      Should almost certainly be using "getPenultimate" with "create = true" so that lender is at least instantiated to an empty object. Make sure to write a test case for this hole to firmly prevent regression.

      Attachments

        Activity

          People

            jobara Justin Obara
            antranig Antranig Basman
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: