aboutsummaryrefslogtreecommitdiffstats
path: root/activeresource
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2008-05-23 01:03:00 +0200
committerXavier Noria <fxn@hashref.com>2008-05-23 01:03:00 +0200
commit63946cfb0ecb1a30b254920df7daee57b36ce7ec (patch)
tree9a589e13703fb5fef8ad09b77c0e03905006e411 /activeresource
parent22a47cb1aeee8ada2396ddf0270c45749b59f16e (diff)
downloadrails-63946cfb0ecb1a30b254920df7daee57b36ce7ec.tar.gz
rails-63946cfb0ecb1a30b254920df7daee57b36ce7ec.tar.bz2
rails-63946cfb0ecb1a30b254920df7daee57b36ce7ec.zip
overall cleanup of "#=>" and other minor details
Diffstat (limited to 'activeresource')
-rw-r--r--activeresource/lib/active_resource/base.rb22
-rw-r--r--activeresource/lib/active_resource/custom_methods.rb10
2 files changed, 16 insertions, 16 deletions
diff --git a/activeresource/lib/active_resource/base.rb b/activeresource/lib/active_resource/base.rb
index b38b4c0194..463ee9f1e7 100644
--- a/activeresource/lib/active_resource/base.rb
+++ b/activeresource/lib/active_resource/base.rb
@@ -34,18 +34,18 @@ module ActiveResource
# from REST web services.
#
# ryan = Person.new(:first => 'Ryan', :last => 'Daigle')
- # ryan.save #=> true
- # ryan.id #=> 2
- # Person.exists?(ryan.id) #=> true
- # ryan.exists? #=> true
+ # ryan.save # => true
+ # ryan.id # => 2
+ # Person.exists?(ryan.id) # => true
+ # ryan.exists? # => true
#
# ryan = Person.find(1)
- # # => Resource holding our newly created Person object
+ # # Resource holding our newly created Person object
#
# ryan.first = 'Rizzle'
- # ryan.save #=> true
+ # ryan.save # => true
#
- # ryan.destroy #=> true
+ # ryan.destroy # => true
#
# As you can see, these are very similar to Active Record's lifecycle methods for database records.
# You can read more about each of these methods in their respective documentation.
@@ -156,8 +156,8 @@ module ActiveResource
# then fail (with a <tt>false</tt> return value) and the validation errors can be accessed on the resource in question.
#
# ryan = Person.find(1)
- # ryan.first #=> ''
- # ryan.save #=> false
+ # ryan.first # => ''
+ # ryan.save # => false
#
# # When
# # PUT http://api.people.com:3000/people/1.xml
@@ -167,8 +167,8 @@ module ActiveResource
# # <errors type="array"><error>First cannot be empty</error></errors>
# #
#
- # ryan.errors.invalid?(:first) #=> true
- # ryan.errors.full_messages #=> ['First cannot be empty']
+ # ryan.errors.invalid?(:first) # => true
+ # ryan.errors.full_messages # => ['First cannot be empty']
#
# Learn more about Active Resource's validation features in the ActiveResource::Validations documentation.
#
diff --git a/activeresource/lib/active_resource/custom_methods.rb b/activeresource/lib/active_resource/custom_methods.rb
index 33a2fffaa0..4c8699288c 100644
--- a/activeresource/lib/active_resource/custom_methods.rb
+++ b/activeresource/lib/active_resource/custom_methods.rb
@@ -7,12 +7,12 @@ module ActiveResource
# :member => { :promote => :put, :deactivate => :delete }
# :collection => { :active => :get }
#
- # This route set creates routes for the following http requests:
+ # This route set creates routes for the following HTTP requests:
#
- # POST /people/new/register.xml #=> PeopleController.register
- # PUT /people/1/promote.xml #=> PeopleController.promote with :id => 1
- # DELETE /people/1/deactivate.xml #=> PeopleController.deactivate with :id => 1
- # GET /people/active.xml #=> PeopleController.active
+ # POST /people/new/register.xml # PeopleController.register
+ # PUT /people/1/promote.xml # PeopleController.promote with :id => 1
+ # DELETE /people/1/deactivate.xml # PeopleController.deactivate with :id => 1
+ # GET /people/active.xml # PeopleController.active
#
# Using this module, Active Resource can use these custom REST methods just like the
# standard methods.