Author: Not specified Language: rails
Description: (v2) Timestamp: 2017-08-03 08:19:51 +0000
View raw paste Parent paste by: Not specified Reply
  1. class ApplicationController < ActionController::Base
  2.   before_action :configure_permitted_parameters, if: :devise_controller?
  3.   protect_from_forgery with: :exception
  4.  
  5.   protected
  6.  
  7.   def configure_permitted_parameters
  8.     added_attrs = [:name, :provider, :uid, :image, :email, :password, :password_confirmation, :remember_me]
  9.     devise_parameter_sanitizer.permit :sign_up, keys: added_attrs
  10.     devise_parameter_sanitizer.permit :account_update, keys: added_attrs
  11.   end
  12. end
View raw paste Parent paste by: Not specified Reply