private function getTypeFromDocBock(ReflectionMethod $method, DocBlockReader $docBlock): ?Type
    {
        $typeDeclaration = $docBlock->getReturnType();
        $blacklist = [
            'Collection',
            'array',
        ];

        if ($typeDeclaration && !in_array($typeDeclaration, $blacklist, true)) {
            return $this->getTypeFromPhpDeclaration($method, $typeDeclaration);
        }

        return null;
    }
private function getTypeFromDocBock(ReflectionMethod $method, DocBlockReader $docBlock): ?Type
    {
        $typeDeclaration = $docBlock->getReturnType();
        $blacklist = [
            'Collection',
            'array',
        ];

        if ($typeDeclaration && !in_array($typeDeclaration, $blacklist, true)) {
            return $this->getTypeFromPhpDeclaration($method, $typeDeclaration);
        }

        return null;
    }
private function getTypeFromDocBock ( ReflectionMethod $ method , DocBlockReader $ docBlock ) : ? Type { $ typeDeclaration = $ docBlock -> getReturnType ( ) ; $ blacklist = [ 'Collection' , 'array' , ] ; if ( $ typeDeclaration && ! in_array ( $ typeDeclaration , $ blacklist , true ) ) { return $ this -> getTypeFromPhpDeclaration ( $ method , $ typeDeclaration ) ; } return null ; }
Get a GraphQL type instance from dock block return type

@param ReflectionMethod $method
@param \GraphQL\Doctrine\DocBlockReader $docBlock

@return null|Type
Get a GraphQL type instance from dock block return type