anchor.diff:     under the License.
     --%>
   
  -<%@page import="org.apache.axis2.context.ConfigurationContext"%>
  +<%@page import="org.apache.axis2.context.ConfigurationContext" %>
   <%@page import="org.wso2.carbon.CarbonConstants" %>
  -<%@page import="org.wso2.carbon.ui.CarbonUIMessage"%>
  -<%@page import="org.wso2.carbon.ui.CarbonUIUtil"%>
  +<%@page import="org.wso2.carbon.ui.CarbonUIMessage" %>
  +<%@page import="org.wso2.carbon.ui.CarbonUIUtil" %>
   <%@page import="org.wso2.carbon.ui.util.CharacterEncoder" %>
   <%@page import="org.wso2.carbon.user.mgt.ui.UserAdminClient" %>
   <%@ page import="org.wso2.carbon.user.mgt.ui.UserAdminUIConstants" %>
  
positive.code:     boolean viewUsers = false;
  
      String BUNDLE = "org.wso2.carbon.userstore.ui.i18n.Resources";
  	ResourceBundle resourceBundle = ResourceBundle.getBundle(BUNDLE, request.getLocale());
  
  	String username = CharacterEncoder.getSafeText(request.getParameter("username"));
      String disPlayName = CharacterEncoder.getSafeText(request.getParameter("disPlayName"));
      if(disPlayName == null || disPlayName.trim().length() == 0){
          disPlayName = username;
      }
  	String[] selectedRoles = request.getParameterValues("selectedRoles");
  	String[] shownRoles = request.getParameterValues("shownRoles");
      String pageNumber = CharacterEncoder.getSafeText(request.getParameter("pageNumber"));
  
      if(request.getParameter("logout") != null){
          logout = Boolean.parseBoolean(request.getParameter("logout"));
      }
      if(request.getParameter("finish") != null){
          finish = Boolean.parseBoolean(request.getParameter("finish"));
      }
      if(request.getParameter("viewRoles") != null){
          viewUsers = Boolean.parseBoolean(request.getParameter("viewRoles"));
      }
  
      try {
          String cookie = (String)session.getAttribute(ServerConstants.ADMIN_SERVICE_COOKIE);
          String backendServerURL = CarbonUIUtil.getServerURL(config.getServletContext(), session);
          ConfigurationContext configContext =
              (ConfigurationContext) config.getServletContext().getAttribute(CarbonConstants.CONFIGURATION_CONTEXT);
          UserAdminClient client = new UserAdminClient(cookie, backendServerURL, configContext);
          ArrayList<String> deletedList = new ArrayList<String>();
          if(selectedRoles != null){
              Arrays.sort(selectedRoles);
          }
  
          if(shownRoles != null){
              for(String name : shownRoles){
                  if(selectedRoles != null){
                      if(Arrays.binarySearch(selectedRoles, name) < 0){
                          deletedList.add(name);
                      }
                  } else {
  
negative.code:                 }
              }
          }
          selectedRoles = addSelectedRoleLists(selectedRoles, (Map<String, Boolean>) session.getAttribute("checkedRolesMap"));
          addDeletedRoleLists(deletedList, (Map<String, Boolean>) session.getAttribute("checkedRolesMap"));
  
          if (viewUsers) {
              client.addRemoveRolesOfUser(Util.decodeHTMLCharacters(username), null,
                      deletedList.toArray(new String[deletedList.size()]));
          } else {
  