Merge "BUG-2184 Fix subtree filtering for identity-ref leaves"