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

Jean-Noel Rouvignac
18.26.2015 ca669ae54f86dbeea277280690584d9f591c7571
opendj-server-legacy/src/main/java/org/opends/admin/ads/ADSContext.java
@@ -567,16 +567,13 @@
      {
        Set<?> memberList =
          (Set<?>)serverGroup.get(ServerGroupProperty.MEMBERS);
        if (memberList != null)
        if (memberList != null && memberList.remove(member))
        {
          if (memberList.remove(member))
          {
            HashMap<ServerGroupProperty, Object> serverGroupProperties =
              new HashMap<ServerGroupProperty, Object>();
            serverGroupProperties.put(ServerGroupProperty.MEMBERS, memberList);
            String groupName = (String)serverGroup.get(ServerGroupProperty.UID);
            updateServerGroup(groupName, serverGroupProperties);
          }
          HashMap<ServerGroupProperty, Object> serverGroupProperties =
            new HashMap<ServerGroupProperty, Object>();
          serverGroupProperties.put(ServerGroupProperty.MEMBERS, memberList);
          String groupName = (String)serverGroup.get(ServerGroupProperty.UID);
          updateServerGroup(groupName, serverGroupProperties);
        }
      }
@@ -2119,16 +2116,12 @@
   * @param serverProperties the server properties.
   * @return the server ID for the given properties or null.
   */
  private static String getServerID(
      Map<ServerProperty, Object> serverProperties)
  private static String getServerID(Map<ServerProperty, Object> serverProperties)
  {
    String result = (String) serverProperties.get(ServerProperty.ID);
    if (result != null)
    if (result != null && result.length() == 0)
    {
      if (result.length() == 0)
      {
        result = null;
      }
      result = null;
    }
    return result;
  }