Magento – Something went wrong while saving the new password Magento 2

change-passwordmagento2passwordpassword-recovery

When I update my password with the "Reset my password" page, it shows me this error: "Something went wrong while saving the new password.".
Please check the screenshot.
I have tried to NULL the rp_token value, but it is not working.

enter image description here

Best Answer

This is an issue in Magento 2.2.6 (check here)

This patch fixes it.

In app/code/Magento/Customer/Model/AccountManagement.php, in function resetPassword:

BEFORE

    $this->sessionManager->destroy();
    $this->destroyCustomerSessions($customer->getId());
    $this->customerRepository->save($customer);

AFTER

    $this->destroyCustomerSessions($customer->getId());
    $this->sessionManager->destroy();
    $this->customerRepository->save($customer);