Sha256: ffaa3d303c9a0f77edfb88ac311eff2c8bcd32da88a7a7434d9d2741afbb7f4d

Contents?: true

Size: 377 Bytes

Versions: 4

Compression:

Stored size: 377 Bytes

Contents

class <%= @job_class_name %> < ActiveJob::Base

  def perform(shop_domain:, webhook:)
    shop = Shop.find_by(shopify_domain: shop_domain)

    if shop.nil?
      logger.error("#{self.class} failed: cannot find shop with domain '#{shop_domain}'")

      raise ActiveRecord::RecordNotFound, "Shop Not Found"
    end

    shop.with_shopify_session do |session|
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
shopify_app-22.5.2 lib/generators/shopify_app/add_declarative_webhook/templates/webhook_job.rb.tt
shopify_app-22.5.1 lib/generators/shopify_app/add_declarative_webhook/templates/webhook_job.rb.tt
shopify_app-22.5.0 lib/generators/shopify_app/add_declarative_webhook/templates/webhook_job.rb.tt
shopify_app-22.4.0 lib/generators/shopify_app/add_declarative_webhook/templates/webhook_job.rb.tt