ProgressRunner<R> (@NotNull ProgressIndicator progressIndicator) { ProgressIndicator myIndicator; try { myIndicator = myProgressIndicatorFuture.isDone() ? myProgressIndicatorFuture.get() : null; } catch (InterruptedException | ExecutionException e) { myIndicator = null; } return progressIndicator.equals(myIndicator) ? this : new ProgressRunner<>(myComputation, isSync, isModal, myThreadToUse, CompletableFuture.completedFuture(progressIndicator)); }