Optionally skip computing flattened paths in GetTreeEntries
Computing flattened paths in GetTreeEntries can be excessively expensive. We should add a flag to optionally skip this step so that clients only need to request them in case they're really needed.