Sha256: 301904e8ffeded99c01fe58ce59a745bf4ed9008179c5f89f4a3061102292755
Contents?: true
Size: 1005 Bytes
Versions: 3
Compression:
Stored size: 1005 Bytes
Contents
require 'rails_connector/core_extensions' module ::RailsConnector def self.load_platform_gem_if_present(name) # :nodoc: if Gem.loaded_specs["infopark_#{name}_connector"] gem_name = "infopark_#{name}_connector" # ensure the other connector is present in exactly the same version gem gem_name, Gem.loaded_specs["infopark_rails_connector"].version require gem_name @platform = name end end # return either :fiona or :cloud depending on the app's configuration. def self.platform @platform end end RailsConnector::load_platform_gem_if_present(:cloud) RailsConnector::load_platform_gem_if_present(:fiona) unless RailsConnector::platform raise "The infopark_rails_connector gem requires "\ "either the infopark_cloud_connector gem (for use with Infopark Cloud Express) or "\ "the infopark_fiona_connector gem (for use with Infopark CMS Fiona). "\ "Add either gem to your Gemfile." end require "rails_connector/engine" if defined?(Rails)
Version data entries
3 entries across 3 versions & 1 rubygems