``` javascript const p = (tree) => { while (tree) { if (tree._key === '$current') { return tree._p.$target } tree = tree._p } } ```