class SameSiteCookieFix::Helpers

Constants

SHOPIFY_APP_VERSION_WITH_SAMESITE_FIX

Public Class Methods

rails_is_defined?() click to toggle source
# File lib/same_site_cookie_fix/helpers.rb, line 10
def self.rails_is_defined?
  defined?(Rails)
end
shopify_app_has_samesite_fix?() click to toggle source
# File lib/same_site_cookie_fix/helpers.rb, line 18
def self.shopify_app_has_samesite_fix?
  Gem::Version.new(ShopifyApp::VERSION) >= Gem::Version.new(SHOPIFY_APP_VERSION_WITH_SAMESITE_FIX)
end
shopify_app_is_defined?() click to toggle source
# File lib/same_site_cookie_fix/helpers.rb, line 14
def self.shopify_app_is_defined?
  defined?(ShopifyApp)
end
should_load_railtie?() click to toggle source
# File lib/same_site_cookie_fix/helpers.rb, line 6
def self.should_load_railtie?
  rails_is_defined? && !(shopify_app_is_defined? && shopify_app_has_samesite_fix?)
end