Sha256: e42381fe2ba2e1de1c792967dd1ff93bc6bb3a1d2d343cd4df2da14172695084

Contents?: true

Size: 160 Bytes

Versions: 5

Compression:

Stored size: 160 Bytes

Contents

module Compel
  module Coercion

    class Hash < Type

      def coerce_value
        Hashie::Mash.new(value).to_hash rescue nil
      end

    end

  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
compel-0.3.7 lib/compel/coercion/types/hash.rb
compel-0.3.6 lib/compel/coercion/types/hash.rb
compel-0.3.4 lib/compel/coercion/types/hash.rb
compel-0.3.2 lib/compel/coercion/types/hash.rb
compel-0.3.1 lib/compel/coercion/types/hash.rb