Method: Devise::ConfirmationsController#create

Defined in:
app/controllers/devise/confirmations_controller.rb

#create {|resource| ... } ⇒ Object

POST /resource/confirmation

Yields:

  • (resource)


10
11
12
13
14
15
16
17
18
19
# File 'app/controllers/devise/confirmations_controller.rb', line 10

def create
  self.resource = resource_class.send_confirmation_instructions(resource_params)
  yield resource if block_given?

  if successfully_sent?(resource)
    respond_with({}, location: after_resending_confirmation_instructions_path_for(resource_name))
  else
    respond_with(resource)
  end
end