Module: CapitalizeAttributes::ClassMethods

Defined in:
lib/capitalize_attributes.rb

Instance Method Summary collapse

Instance Method Details

#capitalize_attribute(attribute) ⇒ Object



18
19
20
# File 'lib/capitalize_attributes.rb', line 18

def capitalize_attribute(attribute)
  self.capitalizable_attribute_names << attribute.to_s
end

#capitalize_attributes(*attributes) ⇒ Object



14
15
16
# File 'lib/capitalize_attributes.rb', line 14

def capitalize_attributes(*attributes)
  attributes.each(&method(:capitalize_attribute))
end