Class: UsersController

Inherits:
ApplicationController
  • Object
show all
Defined in:
lib/generators/authpro/templates/users_controller.rb

Instance Method Summary collapse

Instance Method Details

#createObject



7
8
9
10
11
12
13
14
# File 'lib/generators/authpro/templates/users_controller.rb', line 7

def create
  @user = User.new(user_params)
  if @user.save
    redirect_to root_url, notice: "Signed up!"
  else
    render "new"
  end
end

#newObject



3
4
5
# File 'lib/generators/authpro/templates/users_controller.rb', line 3

def new
  @user = User.new
end