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

matthew_swift
19.31.2007 8228fb82f3ad657adf7832eb05c624bf48c4a30e
opends/src/server/org/opends/server/admin/client/spi/AbstractManagedObject.java
@@ -68,6 +68,7 @@
import org.opends.server.admin.client.ManagementContext;
import org.opends.server.admin.client.MissingMandatoryPropertiesException;
import org.opends.server.admin.client.OperationRejectedException;
import org.opends.server.admin.client.OperationRejectedException.OperationType;
@@ -151,7 +152,8 @@
    }
    if (!exceptions.isEmpty()) {
      throw new MissingMandatoryPropertiesException(exceptions);
      throw new MissingMandatoryPropertiesException(definition
          .getUserFriendlyName(), exceptions, !existsOnServer);
    }
    // Now enforce any constraints.
@@ -175,7 +177,13 @@
    }
    if (!isAcceptable) {
      throw new OperationRejectedException(messages);
      if (existsOnServer) {
        throw new OperationRejectedException(OperationType.MODIFY, definition
            .getUserFriendlyName(), messages);
      } else {
        throw new OperationRejectedException(OperationType.CREATE, definition
            .getUserFriendlyName(), messages);
      }
    }
    // Commit the managed object.