public boolean initParametrizedDuplicates(boolean showDialog) {
    if (myExtractedMethod != null && myParametrizedDuplicates != null) {
      myDuplicates = myParametrizedDuplicates.getDuplicates();
      if (myDuplicates.isEmpty()) {
        return false;
      }
      boolean isSignatureUnchanged = myDuplicates.stream()
                                                 .map(Match::getExtractedParameters)
                                                 .allMatch(List::isEmpty);
      boolean isFoldable = myInputVariables.isFoldable();
      if (!showDialog || isSignatureUnchanged || isFoldable ||
          shouldChangeSignature()) {

        myDuplicates = myParametrizedDuplicates.getDuplicates();
        if (myExtractedMethod.isPhysical()) {
          WriteCommandAction.runWriteCommandAction(myProject, () -> {
            PsiDocumentManager.getInstance(myProject).commitAllDocuments();
            replaceParametrizedMethod();
          });
        }
        else {
          replaceParametrizedMethod();
        }
        myVariableDatum = myParametrizedDuplicates.getVariableDatum();
        return true;
      }
    }
    myDuplicates = myExactDuplicates != null ? myExactDuplicates.getDuplicates() : new ArrayList<>();
    return !myDuplicates.isEmpty();
  }
public boolean initParametrizedDuplicates(boolean showDialog)