Sha256: ea666ac2c80dda8f68fc484f94b11fccad24a66f992b8a90b6e72044e0daf59c

Contents?: true

Size: 287 Bytes

Versions: 1

Compression:

Stored size: 287 Bytes

Contents

require 'rails-env/version'

module RailsEnv
  class Railtie < Rails::Railtie
    initializer 'rails-env' do
      Rails.env.extend(Extension)
    end
  end

  module Extension
    def on(env, &block)
      block.call(Rails.configuration) if Rails.env.to_s == env.to_s
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rails-env-0.1.0 lib/rails-env.rb