Class: AttributeExtensions::Typecasting::SymbolTypecaster

Inherits:
Object
  • Object
show all
Defined in:
lib/attribute_extensions/typecasting/symbol_typecaster.rb

Instance Method Summary collapse

Instance Method Details

#call(value) ⇒ Object



4
5
6
# File 'lib/attribute_extensions/typecasting/symbol_typecaster.rb', line 4

def call(value)
  value.to_sym if value.respond_to?(:to_sym)
end