In "resources/user_resource.inc" the function _user_resource_update contains the line:

if ($key != 'pass' || $key != 'roles') {

Of course this will ALWAYS evaluate to TRUE, the value of $key will always NOT EQUAL one of these values. From the logic and comments of the function I believe it was meant to be:

if ($key != 'pass' && $key != 'roles') {

This change makes the function work as intended by handling the roles and pass values separately in the linese below this one.

The current version doesn't allow updating the password on the User PUT request.

I will include a patch in the comment below.

Comments

tedbow’s picture

Status: Active » Needs review
StatusFileSize
new520 bytes

Here is the patch.

kylebrowning’s picture

Status: Needs review » Fixed
tedbow’s picture

kylebrowning, thanks for committing this

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.