-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
remove unused nickname, image from user object #304
Comments
You can just write a Rails migration to remove those columns and you should be good. The default generator supports them as they tend to be common fields for new projects. Hope this helps! |
what do rails migrations have to do with it? they are already not in my model and I'm getting what is the usual way to use other column names (:name instead of :nickname) eg? overriding |
bump! I do not understand why an assumption could be made that everyone has a nickname and image fields? And how is it that only 3 people on earth have that problem :D |
If someone feels passionately about this, then I'll accept a PR to that effect, so long as tests still pass. |
The reason those fields are used is because that's what's returned by OmniAuth. We could create an initializer setting for this, but it's also really easy to override the controller method to not use those fields, and to remove the columns from the db migration. The amount of code written would be about the same, and the override is more flexible. But I don't feel that strongly about it either way. |
Hi, I'm trying to remove the columns from the database but failing to do so. Is there something else needed to let me remove the columns? |
I want to remove the nickname and image from the user object as I don't need them.
I tried to override the assign_provider_attrs methods from the OmniauthCallbacks controller
config/routes.rb
controllers/overrides/omniauth_callbacks_controller.rb
Did I missed something ? :) thanks
The text was updated successfully, but these errors were encountered: