This change fixes #7 by ensuring the path is always derived correctly against each element.