original_string: public function shouldRetry(Exception $exception, $retryCount)
      {
          $message = $exception->getMessage();
  
          foreach (static::$causes as $cause) {
              if (strstr($message, $cause) !== false) {
                  return $this->reconnect();
              }
          }
  
          return false;
      }
code: public function shouldRetry(Exception $exception, $retryCount)
      {
          $message = $exception->getMessage();
  
          foreach (static::$causes as $cause) {
              if (strstr($message, $cause) !== false) {
                  return $this->reconnect();
              }
          }
  
          return false;
      }
code_tokens: public function shouldRetry ( Exception $ exception , $ retryCount ) { $ message = $ exception -> getMessage ( ) ; foreach ( static :: $ causes as $ cause ) { if ( strstr ( $ message , $ cause ) !== false ) { return $ this -> reconnect ( ) ; } } return false ; }
docstring: Checks whether or not the exception was caused by a lost connection,
  and returns true if it was able to successfully reconnect.
  
  @param Exception $exception The exception to check for its message
  @param int $retryCount The number of times the action has been already called
  @return bool Whether or not it is OK to retry the action
docstring_tokens: Checks whether or not the exception was caused by a lost connection and returns true if it was able to successfully reconnect .