TR: fix PR 14509

Checks user-written object indices on filters to make sure that the indices with depth greater than zero are ok.