protected function getRetryDecider(): callable
    {
        return function (
            $retries,
            Request $request,
            Response $response = null,
            RequestException $exception = null
        ) {
            // Don't retry unless this is a Connection issue
            if (!$exception instanceof ConnectException) {
                return false;
            }

            // Limit the number of retries
            return $retries < 4;
        };
    }
protected function getRetryDecider(): callable
    {
        return function (
            $retries,
            Request $request,
            Response $response = null,
            RequestException $exception = null
        ) {
            // Don't retry unless this is a Connection issue
            if (!$exception instanceof ConnectException) {
                return false;
            }

            // Limit the number of retries
            return $retries < 4;
        };
    }
protected function getRetryDecider ( ) : callable { return function ( $ retries , Request $ request , Response $ response = null , RequestException $ exception = null ) { // Don't retry unless this is a Connection issue if ( ! $ exception instanceof ConnectException ) { return false ; } // Limit the number of retries return $ retries < 4 ; } ; }
Should we retry this failure?

@return \Closure
Should we retry this failure?