Skip to content
This repository has been archived by the owner on Oct 29, 2019. It is now read-only.

Commit

Permalink
SAK-7574 merge from trunk
Browse files Browse the repository at this point in the history
git-svn-id: https://source.sakaiproject.org/svn/user/branches/sakai-2.8.x@95031 66ffb92e-73f9-0310-93c1-f5514f145a0a
  • Loading branch information
ottenhoff@longsight.com committed Jul 12, 2011
1 parent 1770838 commit b4a3d2a
Showing 1 changed file with 12 additions and 7 deletions.
Expand Up @@ -775,6 +775,9 @@ public void doCancel(RunData data, Context context)
public void doRemove(RunData data, Context context)
{
SessionState state = ((JetspeedRunData) data).getPortletSessionState(((JetspeedRunData) data).getJs_peid());

// set mode so we can skip some checks in readUserForm
state.setAttribute("mode", "remove");

// read the form - if rejected, leave things as they are
if (!readUserForm(data, state)) return;
Expand Down Expand Up @@ -1026,14 +1029,16 @@ else if ((mode != null) && (mode.equalsIgnoreCase("edit")) && (!singleUser))
}
}

// make sure we have matching password fields
if (StringUtil.different(pw, pwConfirm))
{
addAlert(state, rb.getString("usecre.pass"));
return false;
if (mode == null || !mode.equalsIgnoreCase("remove")) {
// make sure we have matching password fields
if (StringUtil.different(pw, pwConfirm))
{
addAlert(state, rb.getString("usecre.pass"));
return false;
}

if (pw != null) user.setPassword(pw);
}

if (pw != null) user.setPassword(pw);
}

return true;
Expand Down

0 comments on commit b4a3d2a

Please sign in to comment.