Sha256: 9f59524869ff035b577adc13107348ab685abed55fe796fcca58cd7ccf0d9d57

Contents?: true

Size: 597 Bytes

Versions: 39

Compression:

Stored size: 597 Bytes

Contents

# frozen_string_literal: true

# :enddoc:

module Rails
  # Rerouting will run routing and processing on an email that has already been, or attempted to be, processed.
  class Conductor::ActionMailbox::ReroutesController < Rails::Conductor::BaseController
    def create
      inbound_email = ActionMailbox::InboundEmail.find(params[:inbound_email_id])
      reroute inbound_email

      redirect_to main_app.rails_conductor_inbound_email_url(inbound_email)
    end

    private
      def reroute(inbound_email)
        inbound_email.pending!
        inbound_email.route_later
      end
  end
end

Version data entries

39 entries across 39 versions & 5 rubygems

Version Path
minato_ruby_api_client-0.2.2 vendor/bundle/ruby/3.2.0/gems/actionmailbox-7.1.3.4/app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-8.0.1 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-8.0.0.1 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-7.2.2.1 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-7.1.5.1 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-8.0.0 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-7.2.2 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-7.1.5 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-8.0.0.rc2 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-7.2.1.2 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-7.1.4.2 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-8.0.0.rc1 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-7.2.1.1 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-7.1.4.1 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
actionmailbox-8.0.0.beta1 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
omg-actionmailbox-8.0.0.alpha9 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
omg-actionmailbox-8.0.0.alpha8 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
omg-actionmailbox-8.0.0.alpha7 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
omg-actionmailbox-8.0.0.alpha4 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb
omg-actionmailbox-8.0.0.alpha3 app/controllers/rails/conductor/action_mailbox/reroutes_controller.rb