Sha256: 2a7cf6869982f08c21f443a1fccffa071eba66e1ffb034df4a35d915e16e62d2

Contents?: true

Size: 212 Bytes

Versions: 20

Compression:

Stored size: 212 Bytes

Contents

module MCollective
  module Util
    class IndifferentHash < Hash
      def [](key)
        return super if key?(key)
        return self[key.to_s] if key.is_a?(Symbol)

        super
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
choria-mcorpc-support-2.26.5 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.26.4 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.26.3 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.26.2 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.26.1 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.26.0 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.25.3 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.25.2 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.25.1 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.25.0 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.24.4 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.24.3 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.24.2 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.24.1 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.24.0 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.23.3 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.23.2 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.23.1 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.23.0 lib/mcollective/util/indifferent_hash.rb
choria-mcorpc-support-2.23.0.pre lib/mcollective/util/indifferent_hash.rb