I have the following code in my controller:
login = params[:user_registration][:login]
password = params[:user_registration][:password]
email = params[:user_registration][:email]
It's too verbose and ugly, any smarter way to extract the keys I need?
Userrecord, typical we do the following:User.new(params[:user]). I guess in your case it would beUser.new(params[:user_registration])- not entirely sure why though.