Module: Clearance::App::Controllers::UsersController::InstanceMethods

Defined in:
lib/clearance/app/controllers/users_controller.rb

Instance Method Summary collapse

Instance Method Details

#createObject



24
25
26
27
28
29
30
31
32
33
# File 'lib/clearance/app/controllers/users_controller.rb', line 24

def create
  @user = user_model.new params[:user]
  if @user.save
    ClearanceMailer.deliver_confirmation @user
    flash[:notice] = "You will receive an email within the next few minutes. It contains instructions for you to confirm your account."
    redirect_to url_after_create
  else
    render :action => "new"
  end
end

#newObject



20
21
22
# File 'lib/clearance/app/controllers/users_controller.rb', line 20

def new
  @user = user_model.new(params[:user])
end