cancel
Showing results for 
Search instead for 
Did you mean: 

While changing the password form the my account page User group changed to default customer group

While changing the password form the my account page User group changed to default customer group

For some reason, users if they decide to change their password are automatically returned to the default group.

For example if they are in the VIP group. and they change the password. their password changes but they appear in the general group.

I am in the latest version Magento ver. 2.3.5-p1.

Note: from the admin side if I send the reset the password email for the client, they keep their group. they only lose their group if they do it from the "forgot password" or "my account"

I found this was dealt with older versions of M2 but is happening to me now and I can't fix it.

 

3 REPLIES 3

Re: While changing the password form the my account page User group changed to default customer grou

@starlyn_tejada1 

for a quick fix to this;

File: Magento\Customer\Model\CustomerExtractor

Line 83'ish, change;

$isGroupIdEmpty = !isset($allowedAttributes['group_id']);

To;

$isGroupIdEmpty = !isset($customerData['group_id']);

 

This was Magento core issue and its already been fixed:

https://github.com/magento/magento2/issues/26908

https://github.com/magento/magento2/pull/26958/files

Manish Mittal
https://www.manishmittal.com/

Re: While changing the password form the my account page User group changed to default customer grou

Hi

This is also happening for us, but when the customer changes their name from the front end rather than the pasword.

We are using version 2.3.5-p1

Will the above fix the issue, and if so, can you give me the full path as to where to find the file to edit.

Many thanks

 

 

Re: While changing the password form the my account page User group changed to default customer grou

Hi @starlyn_tejada1,

 

The error is caused by Magento core. To solve it, you need to access the root folder of Magento by using the link: 

app/code/vendor/magento/module-customer/Model/CustomerExtractor.php

 

After that, search for: "$isGroupIdEmpty = !isset($allowedAttributes['group_id']);"

and change it to: "$isGroupIdEmpty = !isset($customerData['group_id']);"

 

Clear cache. 

 

Hope this can help you! Let me know if you need further assistance.

__________

If issue solved, Click Kudos & Accept as Solution

LitExtension - #1 Shopping Cart Migration Expert

LitExtension helps store owners and agencies migrate all important data from one eCommerce platform to another accurately, securely and at the highest speed.

Visit website: http://litextension.com/