Sha256: 32330307ec3948b7e7801772885a2db3c7aebf8cf098b29587c6e16922540a47

Contents?: true

Size: 573 Bytes

Versions: 21

Compression:

Stored size: 573 Bytes

Contents

# frozen_string_literal: true

provider :shopify,
  ShopifyApp.configuration.api_key,
  ShopifyApp.configuration.secret,
  scope: ShopifyApp.configuration.scope,
  setup: lambda { |env|
    strategy = env['omniauth.strategy']

    shopify_auth_params = strategy.session['shopify.omniauth_params']&.with_indifferent_access
    shop = if shopify_auth_params.present?
      "https://#{shopify_auth_params[:shop]}"
    else
      ''
    end

    strategy.options[:client_options][:site] = shop
    strategy.options[:old_client_secret] = ShopifyApp.configuration.old_secret
  }

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
shopify_app-11.6.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.5.1 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.4.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.3.2 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.3.1 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.3.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.2.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.1.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.0.2 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.0.1 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-11.0.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-10.0.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-9.0.4 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-9.0.3 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-9.0.2 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-9.0.1 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-9.0.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-8.6.1 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-8.6.0 lib/generators/shopify_app/install/templates/shopify_provider.rb
shopify_app-8.5.1 lib/generators/shopify_app/install/templates/shopify_provider.rb