Class: ConfirmationsController

Inherits:
ApplicationController
  • Object
show all
Includes:
Devise::Controllers::Common, Devise::Controllers::InternalHelpers
Defined in:
app/controllers/confirmations_controller.rb

Instance Method Summary collapse

Methods included from Devise::Controllers::Common

#create, #new

Methods included from Devise::Controllers::InternalHelpers

#devise_controller?, #devise_mapping, included, #resource, #resource_class, #resource_name

Instance Method Details

#showObject

GET /resource/confirmation?confirmation_token=abcdef



6
7
8
9
10
11
12
13
14
15
# File 'app/controllers/confirmations_controller.rb', line 6

def show
  self.resource = resource_class.confirm!(:confirmation_token => params[:confirmation_token])

  if resource.errors.empty?
    set_flash_message :notice, :confirmed
    (resource_name, resource)
  else
    render_with_scope :new
  end
end