src/Backoff.php
protected function getDefaultDecider()
    {
        return function ($retry, $maxAttempts, $result = null, $exception = null) {
            if($retry >= $maxAttempts && ! is_null($exception)) {
                throw  $exception;
            }

            return $retry < $maxAttempts && !is_null($exception);
        };
    }
protected function getDefaultDecider()
    {
        return function ($retry, $maxAttempts, $result = null, $exception = null) {
            if($retry >= $maxAttempts && ! is_null($exception)) {
                throw  $exception;
            }

            return $retry < $maxAttempts && !is_null($exception);
        };
    }
protected function getDefaultDecider ( ) { return function ( $ retry , $ maxAttempts , $ result = null , $ exception = null ) { if ( $ retry >= $ maxAttempts && ! is_null ( $ exception ) ) { throw $ exception ; } return $ retry < $ maxAttempts && ! is_null ( $ exception ) ; } ; }
Gets a default decider that simply check exceptions and maxattempts
@return \Closure
Gets a default decider that simply check exceptions and maxattempts