rabbitmq-tests/src/test/java/com/datastax/oss/starlight/rabbitmqtests/javaclient/QueueingConsumer.java
private Delivery handle(Delivery delivery) {
    if (delivery == POISON || delivery == null && (_shutdown != null || _cancelled != null)) {
      if (delivery == POISON) {
        _queue.add(POISON);
        if (_shutdown == null && _cancelled == null) {
          throw new IllegalStateException(
              "POISON in queue, but null _shutdown and null _cancelled. "
                  + "This should never happen, please report as a BUG");
        }
      }
      if (null != _shutdown) throw Utility.fixStackTrace(_shutdown);
      if (null != _cancelled) throw Utility.fixStackTrace(_cancelled);
    }
    return delivery;
  }
/**
   * If delivery is not POISON nor null, return it.
   *
   * <p>If delivery, _shutdown and _cancelled are all null, return null.
   *
   * <p>If delivery is POISON re-insert POISON into the queue and throw an exception if POISONed for
   * no reason.
   *
   * <p>Otherwise, if we are in shutdown mode or cancelled, throw a corresponding exception.
   */
If delivery is not POISON nor null, return it.
If delivery, _shutdown and _cancelled are all null, return null.

If delivery is POISON re-insert POISON into the queue and throw an exception if POISONed for
no reason.

Otherwise, if we are in shutdown mode or cancelled, throw a corresponding exception.
If delivery is not POISON nor null return it . If delivery _shutdown and _cancelled are all null return null . If delivery is POISON re - insert POISON into the queue and throw an exception if POISONed for no reason . Otherwise if we are in shutdown mode or cancelled throw a corresponding exception .
private Delivery handle(Delivery delivery) {
    if (delivery == POISON || delivery == null && (_shutdown != null || _cancelled != null)) {
      if (delivery == POISON) {
        _queue.add(POISON);
        if (_shutdown == null && _cancelled == null) {
          throw new IllegalStateException(
              "POISON in queue, but null _shutdown and null _cancelled. "
                  + "This should never happen, please report as a BUG");
        }
      }
      if (null != _shutdown) throw Utility.fixStackTrace(_shutdown);
      if (null != _cancelled) throw Utility.fixStackTrace(_cancelled);
    }
    return delivery;
  }
private Delivery handle ( Delivery delivery ) { if ( delivery == POISON || delivery == null && ( _shutdown != null || _cancelled != null ) ) { if ( delivery == POISON ) { _queue . add ( POISON ) ; if ( _shutdown == null && _cancelled == null ) { throw new IllegalStateException ( "POISON in queue, but null _shutdown and null _cancelled. " + "This should never happen, please report as a BUG" ) ; } } if ( null != _shutdown ) throw Utility . fixStackTrace ( _shutdown ) ; if ( null != _cancelled ) throw Utility . fixStackTrace ( _cancelled ) ; } return delivery ; }
If delivery is not POISON nor null, return it.
If delivery is not POISON nor null return it .