Skip to content
Commit d72a9a2b authored by Kohsuke Kawaguchi's avatar Kohsuke Kawaguchi
Browse files

fixed a bug in the neighbor field discovery.

Previously, the code was "find the nearby element of the expected @name,
then make sure it has gotten the right parent."

So if the structure is like:

  {/* outer object */
      name: "parent-name",  /* A */

      child1: {/* inner object */
        name: "child-name" /* B */
      },

      child2: {/* inner object */
        name: "child-name" /* C */
      }
  }

... and if we are looking for "../name", it finds B, and it gets
rejected, so we won't be able to find A, which is what we are supposed
to find.

With this change, we keep trying until we find the right one,
so the above case will correctly return A.
parent ec5812c8
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment