cybertooth-io / ermahgerd-rails-api-jwt

Rails 5+ API, JWT_Session, Pundit, JSONAPI, Sidekiq, PostgreSQL.
0 stars 0 forks source link

UserResource - Some Changes & Improvements #19

Closed nadnoslen closed 5 years ago

nadnoslen commented 5 years ago

On Update, we should permit the password and password_confirmed fields. Put it in the self.updatable_fields override. Test it.

On Create, we should build a before a hook that automatically creates a password and password_confirmed field should it have not been passed in the payload. Put it in the self.creatable_fields override.

nadnoslen commented 5 years ago

I've added to creatable and updatable but am not putting the before callback in because that can screw stuff up