public function retriesLeft($key, $maxAttempts)
    {
        $attempts = $this->attempts($key);

        return ($attempts === 0) ? $maxAttempts : $maxAttempts - $attempts + 1;
    }
public function retriesLeft($key, $maxAttempts)
    {
        $attempts = $this->attempts($key);

        return ($attempts === 0) ? $maxAttempts : $maxAttempts - $attempts + 1;
    }
public function retriesLeft ( $ key , $ maxAttempts ) { $ attempts = $ this -> attempts ( $ key ) ; return ( $ attempts === 0 ) ? $ maxAttempts : $ maxAttempts - $ attempts + 1 ; }
Get the number of retries left for the given key.

@param  string  $key
@param  int  $maxAttempts
@return int
Get the number of retries left for the given key .