From e8c3ae6a23cc78bf01cb7b462089cc734a1c1d89 Mon Sep 17 00:00:00 2001
From: Gaetan Boismal <gaetan.boismal@forgerock.com>
Date: Mon, 23 Mar 2015 14:33:24 +0000
Subject: [PATCH] OPENDJ-1714: Code cleanup
---
opendj-server-legacy/src/main/java/org/opends/server/tools/InstallDSArgumentParser.java | 14 +++++++-------
1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/opendj-server-legacy/src/main/java/org/opends/server/tools/InstallDSArgumentParser.java b/opendj-server-legacy/src/main/java/org/opends/server/tools/InstallDSArgumentParser.java
index 61f5e04..37e29fb 100644
--- a/opendj-server-legacy/src/main/java/org/opends/server/tools/InstallDSArgumentParser.java
+++ b/opendj-server-legacy/src/main/java/org/opends/server/tools/InstallDSArgumentParser.java
@@ -538,9 +538,10 @@
/**
* Checks that there are no conflicts with the import data arguments.
- * @param errorMessages the list of messages to which we add the error
- * messages describing the problems encountered during the execution of the
- * checking.
+ *
+ * @param errorMessages
+ * the list of messages to which we add the error messages describing
+ * the problems encountered during the execution of the checking.
*/
private void checkImportDataArguments(Collection<LocalizableMessage> errorMessages)
{
@@ -579,16 +580,15 @@
errorMessages.add(conflictingArgs(skippedImportFileArg, sampleDataArg));
}
- if (noPromptArg.isPresent() && !baseDNArg.isPresent() &&
- baseDNArg.getDefaultValue() == null)
+ final boolean noBaseDNProvided = !baseDNArg.isPresent() && baseDNArg.getDefaultValue() == null;
+ if (noPromptArg.isPresent() && noBaseDNProvided)
{
Argument[] args = {importLDIFArg, addBaseEntryArg, sampleDataArg};
for (Argument arg : args)
{
if (arg.isPresent())
{
- errorMessages.add(ERR_INSTALLDS_NO_BASE_DN_AND_CONFLICTING_ARG.get(
- "--"+arg.getLongIdentifier()));
+ errorMessages.add(ERR_INSTALLDS_NO_BASE_DN_AND_CONFLICTING_ARG.get("--" + arg.getLongIdentifier()));
}
}
}
--
Gitblit v1.10.0