From 8a1468eef6a6567b7420ab83948f5f39118b2dcb Mon Sep 17 00:00:00 2001 From: deeeki Date: Sat, 14 Jun 2014 01:56:55 +0900 Subject: [ci skip] Clarify ActiveModel::Model docs ActiveModel attributes initialized with String return String values --- activemodel/lib/active_model/model.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'activemodel') diff --git a/activemodel/lib/active_model/model.rb b/activemodel/lib/active_model/model.rb index 63716eebb1..640024eaa1 100644 --- a/activemodel/lib/active_model/model.rb +++ b/activemodel/lib/active_model/model.rb @@ -16,8 +16,8 @@ module ActiveModel # end # # person = Person.new(name: 'bob', age: '18') - # person.name # => 'bob' - # person.age # => 18 + # person.name # => "bob" + # person.age # => "18" # # Note that, by default, ActiveModel::Model implements persisted? # to return +false+, which is the most common case. You may want to override @@ -74,7 +74,7 @@ module ActiveModel # # person = Person.new(name: 'bob', age: '18') # person.name # => "bob" - # person.age # => 18 + # person.age # => "18" def initialize(params={}) params.each do |attr, value| self.public_send("#{attr}=", value) -- cgit v1.2.3