mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
8a0a103495
We didn't end up using the mailroom metaphor directly, so let's stick with a more conventional naming strategy.
11 lines
263 B
Ruby
11 lines
263 B
Ruby
module ActionMailbox::InboundEmail::Routable
|
|
extend ActiveSupport::Concern
|
|
|
|
included do
|
|
after_create_commit :route_later, if: ->(inbound_email) { inbound_email.pending? }
|
|
end
|
|
|
|
def route_later
|
|
ActionMailbox::RoutingJob.perform_later self
|
|
end
|
|
end
|