private static @NotNull String getDocumentName() {
    if (!PlatformUtils.isCommercialEdition()) {
      if (PlatformUtils.isCommunityEdition()) {
        return shouldUseEAPAgreement()? DEFAULT_DOC_EAP_NAME : EULA_COMMUNITY_DOCUMENT_NAME;
      }
      if (PlatformUtils.isJetBrainsClient()) {
        return CWM_GUEST_EULA_NAME;
      }
      if (PlatformUtils.isGateway()) {
        return shouldUseEAPAgreement()? DEFAULT_DOC_EAP_NAME : DEFAULT_DOC_NAME;
      }
      return shouldUseEAPAgreement()? PRIVACY_POLICY_EAP_DOCUMENT_NAME : PRIVACY_POLICY_DOCUMENT_NAME;
    }

    try {
      String docName = Files.readString(getDocumentNameFile());
      if (isValidFileName(docName)) {
        return docName;
      }
    }
    catch (IOException ignored) {
    }
    return shouldUseEAPAgreement()? DEFAULT_DOC_EAP_NAME : DEFAULT_DOC_NAME;
  }
private static @NotNull String getDocumentName()