Sha256: f5fd65b6ede936534663ffd179ac268e84802a75f09253fd3981cb3dfde1da52

Contents?: true

Size: 608 Bytes

Versions: 26

Compression:

Stored size: 608 Bytes

Contents

require 'hashie/mash'

module OmniAuth
  # Generic helper hash that allows method access on deeply nested keys.
  class KeyStore < ::Hashie::Mash
    # Disables warnings on Hashie 3.5.0+ for overwritten keys
    def self.override_logging
      require 'hashie/version'
      return unless Gem::Version.new(Hashie::VERSION) >= Gem::Version.new('3.5.0')

      if respond_to?(:disable_warnings)
        disable_warnings
      else
        define_method(:log_built_in_message) { |*| }
        private :log_built_in_message
      end
    end

    # Disable on loading of the class
    override_logging
  end
end

Version data entries

26 entries across 25 versions & 2 rubygems

Version Path
tdiary-5.0.4 vendor/bundle/gems/omniauth-1.6.1/lib/omniauth/key_store.rb
omniauth-1.6.1 lib/omniauth/key_store.rb
omniauth-1.6.0 lib/omniauth/key_store.rb
omniauth-1.5.0 lib/omniauth/key_store.rb
omniauth-1.4.1 lib/omniauth/key_store.rb
omniauth-1.4.0 lib/omniauth/key_store.rb