move getSubtypes inline