allow get_type_hierarchy to return from an id rather than the entire hierarchy

.