Skip to content

User setPassword cause Object not found again #342

Closed
@flessard

Description

@flessard

Why the field resetPasswordCode become empty on save but the password cause Object not found error

user.set('resetPasswordCode', '');
user.setPassword(request.params.password);
return user.save(null, { useMasterKey: true });

Anyone can help me or can point me how to fix this bug ?
Or what is the best way to update password user in cloud code ?

if i comment this line, everything Is working perfectly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions