Skip to content

Conversation

@sampaiodiego
Copy link
Member

Proposed changes (including videos or screenshots)

Issue(s)

Closes #19604

Steps to test or reproduce

Further comments

@rasos
Copy link
Contributor

rasos commented Feb 17, 2021

Great to see this fix, as it is really security related, if users can not change their passwords. Also other profile settings (email, avatar image etc) could not be changed.

const canChangePasswordForOAuth = rcSettings.get('Accounts_AllowPasswordChangeForOAuthUsers');
if (canChangePasswordForOAuth || user.services?.password) {
// Should be the last check to prevent error when trying to check password for users without password
if (settings.newPassword && rcSettings.get('Accounts_AllowPasswordChange') === true) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can remove the === true part of this

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep, this is an old code that was just re-indented, but I agree 👍

Ishrat-Manzoor
Ishrat-Manzoor previously approved these changes Feb 17, 2021
@sampaiodiego sampaiodiego merged commit 961706b into develop Feb 18, 2021
@sampaiodiego sampaiodiego deleted the fix-set-user-password branch February 18, 2021 01:40
@sampaiodiego sampaiodiego mentioned this pull request Feb 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

QA-Regression: User is not able to change the account password.

6 participants