app/controllers/confirmations_controller.rb
# Remove the first skip_before_filter (:require_no_authentication) if you
# don't want to enable logged users to access the confirmation page.
Remove the first skip_before_filter (:require_no_authentication) if you
don't want to enable logged users to access the confirmation page.
Remove the first skip_before_filter ( : require_no_authentication ) if you don ' t want to enable logged users to access the confirmation page .
def confirm
    @original_token = params[resource_name].try(:[], :confirmation_token)
    self.resource = resource_class.find_by_confirmation_token!(@original_token)
    resource.assign_attributes(permitted_params) unless params[resource_name].nil?
    if resource.valid? && resource.password_match?
      self.resource.confirm!
      set_flash_message :notice, :confirmed
      sign_in_and_redirect resource_name, resource
    else
      render :action => 'show'
    end
  end
def confirm @original_token = params [ resource_name ] . try ( :[] , :confirmation_token ) self . resource = resource_class . find_by_confirmation_token! ( @original_token ) resource . assign_attributes ( permitted_params ) unless params [ resource_name ] . nil? if resource . valid? && resource . password_match? self . resource . confirm! set_flash_message :notice , :confirmed sign_in_and_redirect resource_name , resource else render :action => 'show' end end
Remove the first skip_before_filter (:require_no_authentication) if you
don't want to enable logged users to access the confirmation page.
Remove the first skip_before_filter ( : require_no_authentication ) if you don ' t want to enable logged users to access the confirmation page .