Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User.login can’t be modified once set #116

Open
brchristian opened this issue Jan 16, 2018 · 1 comment · May be fixed by #212
Open

User.login can’t be modified once set #116

brchristian opened this issue Jan 16, 2018 · 1 comment · May be fixed by #212

Comments

@brchristian
Copy link
Contributor

I’m using a vanilla Solidus 2.4.2 store with solidus_auth_devised.

It looks like the default user created has email: [email protected] and login: [email protected]. If I go to the /account/edit page, I can modify the User’s email.

Now I have a situation where I have email: [email protected] and login: [email protected]. It seems there is simply no way to modify the login attribute once the user is created. What’s slightly weirder, it is email, not login, that is used to log in. :)

What should we do here?

My suggestion would be that if this extension is built to use the email attribute as the login by default, than we should either:

  1. leave the actual login attribute as nil when creating a new user.
  2. save any new changes to the email field to the login attribute as well.

@jhawthorn perhaps you can weigh in here. I’d be happy to prepare a PR once we settle on what we think the behavior should be. I’m just finding it weird to have accounts with this legacy login field set to whatever the initial value was and not able to be modified later. Let me know what you think!

@spaghetticode
Copy link
Member

I'm looking at the current code, and it seems to me that the login field does not see much use here.

I'm wondering if this field still exists just for historical reasons. What about removing it (maybe only for new installations)?

@willianveiga willianveiga linked a pull request Jun 2, 2021 that will close this issue
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 a pull request may close this issue.

2 participants