@Override
    protected void onNewResultImpl(@Nullable EncodedImage newResult, @Status int status) {
      ImageRequest request = mProducerContext.getImageRequest();
      boolean isLast = isLast(status);
      boolean isGoodEnough =
          ThumbnailSizeChecker.isImageBigEnough(newResult, request.getResizeOptions());
      if (newResult != null && (isGoodEnough || request.getLocalThumbnailPreviewsEnabled())) {
        if (isLast && isGoodEnough) {
          getConsumer().onNewResult(newResult, status);
        } else {
          int alteredStatus = turnOffStatusFlag(status, IS_LAST);
          getConsumer().onNewResult(newResult, alteredStatus);
        }
      }
      if (isLast && !isGoodEnough && !request.getLoadThumbnailOnlyForAndroidSdkAboveQ()) {
        EncodedImage.closeSafely(newResult);

        mInputProducer2.produceResults(getConsumer(), mProducerContext);
      }
    }
Producer that coordinates fetching two separate images.

<p>The first producer is kicked off, and once it has returned all its results, the second
producer is kicked off if necessary.
imagepipeline/src/main/java/com/facebook/imagepipeline/producers/BranchOnSeparateImagesProducer.java