fixed bug with hierarchy tree indexing only one tree