tomatoes icon indicating copy to clipboard operation
tomatoes copied to clipboard

Remove deprecated User fields

Open potomak opened this issue 8 years ago • 4 comments

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

potomak avatar Oct 06 '16 01:10 potomak

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 avatar Mar 20 '17 21:03 morrme

@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.

potomak avatar Mar 21 '17 13:03 potomak

Do you want the fields removed from existing documents as well ( like User.each { |user| user.unset(:uid) } etc?

morrme avatar Mar 21 '17 19:03 morrme

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.

potomak avatar Mar 21 '17 19:03 potomak