Sha256: b3b6a6537656513f5be245636daa43c5f25a037bb71eef4f6edc508aaf250fc9

Contents?: true

Size: 311 Bytes

Versions: 3

Compression:

Stored size: 311 Bytes

Contents

# frozen_string_literal: true

module SolidusSubscriptions
  class OrderSubscriber
    include Omnes::Subscriber

    handle :order_finalized, with: :create_subscription

    def create_subscription(event)
      SolidusSubscriptions::CreateSubscriptionJob.perform_later(event.payload[:order])
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
solidus_subscriptions-2.0.2 app/subscribers/solidus_subscriptions/order_subscriber.rb
solidus_subscriptions-2.0.1 app/subscribers/solidus_subscriptions/order_subscriber.rb
solidus_subscriptions-2.0.0 app/subscribers/solidus_subscriptions/order_subscriber.rb