Sha256: 29dd2e8c6726b4e7f4018f9ce37205fb5727027b998be3e240f00cd4d2d64375
Contents?: true
Size: 444 Bytes
Versions: 4
Compression:
Stored size: 444 Bytes
Contents
require_relative "./engine/domain_middleware" module PCO class URL class Engine < Rails::Engine def self.domain Thread.current[:pco_url_domain] end def self.domain=(d) Thread.current[:pco_url_domain] = d end initializer "pco_url.add_middleware" do |app| app.middleware.use PCO::URL::Engine::DomainMiddleware if Rails.env.development? || Rails.env.test? end end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
pco-url-2.1.3 | lib/pco/url/engine.rb |
pco-url-2.1.2 | lib/pco/url/engine.rb |
pco-url-2.1.1 | lib/pco/url/engine.rb |
pco-url-2.1.0 | lib/pco/url/engine.rb |