mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Chris Ridd
06.49.2013 33f99d27d8acad1248de8417df9c443982da1d25
Fix OPENDJ-797 Custom Password policy did not survive upgrade to 2.5.0-Xpress1
1 files modified
19 ■■■■■ changed files
opends/src/server/org/opends/server/admin/client/ldap/LDAPDriver.java 19 ●●●●● patch | view | raw | blame | history
opends/src/server/org/opends/server/admin/client/ldap/LDAPDriver.java
@@ -23,6 +23,7 @@
 *
 *
 *      Copyright 2008-2009 Sun Microsystems, Inc.
 *      Portions Copyright 2013 ForgeRock, AS.
 */
package org.opends.server.admin.client.ldap;
@@ -634,14 +635,6 @@
      activeValues.add(value);
    }
    if (activeValues.isEmpty() && pd.hasOption(PropertyOption.MANDATORY)) {
      // The active values maybe empty because of a previous
      // exception.
      if (exception == null) {
        exception = new PropertyIsMandatoryException(pd);
      }
    }
    // Get the property's default values.
    Collection<PD> defaultValues;
    try {
@@ -652,6 +645,16 @@
    }
    newProperties.addProperty(pd, defaultValues, activeValues);
    if (activeValues.isEmpty() && defaultValues.isEmpty()
        && pd.hasOption(PropertyOption.MANDATORY)) {
      // The active values maybe empty because of a previous
      // exception.
      if (exception == null) {
        exception = new PropertyIsMandatoryException(pd);
      }
    }
    if (exception != null) {
      throw exception;
    }