Skip to content

Commit

Permalink
XWIKI-19804: Bulletproof user API
Browse files Browse the repository at this point in the history
  • Loading branch information
surli committed Jun 9, 2022
1 parent 5be1cc0 commit 0b732f2
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,9 @@ public XWikiUser getUser()
*/
public void setDisabledStatus(boolean disabledStatus)
{
this.user.setDisabled(disabledStatus, getXWikiContext());
if (hasAdminRights()) {
this.user.setDisabled(disabledStatus, getXWikiContext());
}
}

/**
Expand Down

0 comments on commit 0b732f2

Please # to comment.