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

Old users without a name cannot reset their passwords #401

Closed
jfly opened this issue Feb 23, 2016 · 1 comment
Closed

Old users without a name cannot reset their passwords #401

jfly opened this issue Feb 23, 2016 · 1 comment
Assignees
Labels
META: good first issue Small/easy change which is a good introduction to working in the WCA repo TYPE: bug Bug reported by a stakeholder

Comments

@jfly
Copy link
Contributor

jfly commented Feb 23, 2016

This is due to the presense validation we have on name: https://github.com/jfly/worldcubeassociation.org/blob/005887514b443eea6ba27062897635a00763ad94/WcaOnRails/app/models/user.rb#L24, that I added here: e2a57af#diff-572f7c99c29e70c2f7cbb9c219270579R5.

Also see #400.

@jfly jfly added TYPE: bug Bug reported by a stakeholder META: good first issue Small/easy change which is a good introduction to working in the WCA repo labels Feb 23, 2016
@jfly jfly changed the title Brand new users cannot reset their passwords Old users without a name cannot reset their passwords Feb 23, 2016
@jfly
Copy link
Contributor Author

jfly commented Feb 23, 2016

I fixed this by running UPDATE users SET name=email WHERE users.name IS NULL on the production server, so now everyone has a name.

> SELECT COUNT(*) FROM users WHERE users.name = ""
0

> SELECT COUNT(*) FROM users WHERE users.name IS NULL
0

@jfly jfly closed this as completed Feb 23, 2016
@jfly jfly self-assigned this Feb 23, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
META: good first issue Small/easy change which is a good introduction to working in the WCA repo TYPE: bug Bug reported by a stakeholder
Projects
None yet
Development

No branches or pull requests

1 participant