REVIEW-4002: Avoid checking expected component selector type twice.