-
Notifications
You must be signed in to change notification settings - Fork 229
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
Correct variable name and remove unneeded #261
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs some housekeeping stuff, but the code change itself looks good.
authentication = send(authentications).build(sorcery_config.provider_uid_attribute_name => uid, | ||
sorcery_config.provider_attribute_name => provider) | ||
user.sorcery_adapter.save(validate: false) | ||
authentication.sorcery_adapter.save(validate: false) | ||
else | ||
user = false | ||
false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, looking closer at this, I think this changes the return value when the authentication is present. Previously it would return authentication
, but with this change it would instead return authentication.sorcery_adapter.save(validate: false)
as that's the last value called in the method.
Can you revert the second part of this, and keep it to just renaming the variable to be more accurate?
I want to add changing about two points. It's simple refectoring.