tomatoes
tomatoes copied to clipboard
Remove deprecated User fields
Before authorizations embedded documents existed, auth data was stored in the users documents. Active users' data should be up to date, because auth data is updated during session creation.
Let's remove User
's deprecated attributes and update finders (#find_by_omniauth
).
User
attributes to be removed:
-
provider
-
uid
-
token
-
gravatar_id
I have found the attributes mentioned in the app/models/user.rb
file. What other file or data work would need to be done to be able to help?
@morrme remove the fields, run the app and test your change.
I'd suggest to add a test for a case some users still don't have authorizations embedded documents.
Do you want the fields removed from existing documents as well ( like User.each { |user| user.unset(:uid) }
etc?
Yes, but for that there should be a rake task that I could use against the prod database.
@morrme that would be a delicate task that I should work on, and I guess that is a blocker for this issue.
Let's put this on hold please.