lib/mobility/backends/serialized.rb in mobility-0.8.13 vs lib/mobility/backends/serialized.rb in mobility-1.0.0.alpha

- old
+ new

@@ -21,12 +21,10 @@ @see Mobility::Backends::ActiveRecord::Serialized @see Mobility::Backends::Sequel::Serialized =end module Serialized - extend Backend::OrmDelegator - class << self # @!group Backend Configuration # @option options [Symbol] format (:yaml) Serialization format # @raise [ArgumentError] if a format other than +:yaml+ or +:json+ is passed in @@ -38,10 +36,10 @@ # @!endgroup def serializer_for(format) lambda do |obj| return if obj.nil? - if obj.is_a? Hash + if obj.is_a? ::Hash obj = obj.inject({}) do |translations, (locale, value)| translations[locale] = value.to_s if Util.present?(value) translations end else