code: function getContentTypeById($spaceId, $id)
      {
          return $this->contentTypeRepo->findNewestById($spaceId, $id)->getOrCall(function () use ($spaceId, $id) {
              throw new InvalidArgumentException(
                  sprintf(
                      'Content type "%s" in space "%s" not found!',
                      $id,
                      $spaceId
                  )
              );
          });
      }
docs: @param string $spaceId
  @param string $id
  
  @return ContentfulContentType
  
  @throws InvalidArgumentException If contenty type cannot be found.