lib/representable/definition.rb in representable-0.12.0 vs lib/representable/definition.rb in representable-0.13.0

- old
+ new

@@ -6,10 +6,10 @@ def initialize(sym, options={}) @name = sym.to_s @array = options[:collection] @from = (options[:from] || name).to_s - @sought_type = options[:class] || options[:class] || :text # TODO: deprecate :class in 1.0. + @sought_type = options[:class] || options[:as] || :text # TODO: deprecate :as in 1.0. @default = options[:default] @default ||= [] if array? @representer_module = options[:extend] # DISCUSS: move to Representable::DCI? # FIXME: move me to xml.