diff options
6 files changed, 4 insertions, 13 deletions
diff --git a/actionpack/lib/action_dispatch/testing/assertions/selector.rb b/actionpack/lib/action_dispatch/testing/assertions/selector.rb index 2207a43afc..e481f3b245 100644 --- a/actionpack/lib/action_dispatch/testing/assertions/selector.rb +++ b/actionpack/lib/action_dispatch/testing/assertions/selector.rb @@ -155,8 +155,6 @@ module ActionDispatch # If the method is called with a block, once all equality tests are # evaluated the block is called with an array of all matched elements. # - # ==== Examples - # # # At least one form element # assert_select "form" # diff --git a/actionpack/lib/action_view/helpers/form_helper.rb b/actionpack/lib/action_view/helpers/form_helper.rb index b5965b21b7..bebd39d42d 100644 --- a/actionpack/lib/action_view/helpers/form_helper.rb +++ b/actionpack/lib/action_view/helpers/form_helper.rb @@ -461,8 +461,6 @@ module ActionView # doesn't create the form tags themselves. This makes fields_for suitable # for specifying additional model objects in the same form. # - # === Generic Examples - # # Although the usage and purpose of +field_for+ is similar to +form_for+'s, # its method signature is slightly different. Like +form_for+, it yields # a FormBuilder object associated with a particular model object to a block, diff --git a/activerecord/lib/active_record/autosave_association.rb b/activerecord/lib/active_record/autosave_association.rb index 907fe70522..704998301c 100644 --- a/activerecord/lib/active_record/autosave_association.rb +++ b/activerecord/lib/active_record/autosave_association.rb @@ -32,8 +32,6 @@ module ActiveRecord # autosave callbacks are executed. Placing your callbacks after # associations is usually a good practice. # - # == Examples - # # === One-to-one Example # # class Post diff --git a/activerecord/lib/active_record/integration.rb b/activerecord/lib/active_record/integration.rb index 23c272ef12..7bdc1bd4c6 100644 --- a/activerecord/lib/active_record/integration.rb +++ b/activerecord/lib/active_record/integration.rb @@ -29,8 +29,6 @@ module ActiveRecord # Returns a cache key that can be used to identify this record. # - # ==== Examples - # # Product.new.cache_key # => "products/new" # Product.find(5).cache_key # => "products/5" (updated_at not available) # Person.find(5).cache_key # => "people/5-20071224150000" (updated_at available) diff --git a/activerecord/lib/active_record/query_cache.rb b/activerecord/lib/active_record/query_cache.rb index 38e18b32a4..2cf75bcfc4 100644 --- a/activerecord/lib/active_record/query_cache.rb +++ b/activerecord/lib/active_record/query_cache.rb @@ -4,6 +4,7 @@ module ActiveRecord class QueryCache module ClassMethods # Enable the query cache within the block if Active Record is configured. + # If it's not, it willl execute the given block. def cache(&block) if ActiveRecord::Base.connected? connection.cache(&block) @@ -13,6 +14,7 @@ module ActiveRecord end # Disable the query cache within the block if Active Record is configured. + # If it's not, it willl execute the given block. def uncached(&block) if ActiveRecord::Base.connected? connection.uncached(&block) diff --git a/activerecord/lib/active_record/querying.rb b/activerecord/lib/active_record/querying.rb index 45f6a78428..5ddcaee6be 100644 --- a/activerecord/lib/active_record/querying.rb +++ b/activerecord/lib/active_record/querying.rb @@ -26,14 +26,13 @@ module ActiveRecord # MySQL specific terms will lock you to using that particular database engine or require you to # change your call if you switch engines. # - # ==== Examples # # A simple SQL query spanning multiple tables # Post.find_by_sql "SELECT p.title, c.author FROM posts p, comments c WHERE p.id = c.post_id" - # > [#<Post:0x36bff9c @attributes={"title"=>"Ruby Meetup", "first_name"=>"Quentin"}>, ...] + # # => [#<Post:0x36bff9c @attributes={"title"=>"Ruby Meetup", "first_name"=>"Quentin"}>, ...] # # # You can use the same string replacement techniques as you can with ActiveRecord#find # Post.find_by_sql ["SELECT title FROM posts WHERE author = ? AND created > ?", author_id, start_date] - # > [#<Post:0x36bff9c @attributes={"title"=>"The Cheap Man Buys Twice"}>, ...] + # # => [#<Post:0x36bff9c @attributes={"title"=>"The Cheap Man Buys Twice"}>, ...] def find_by_sql(sql, binds = []) logging_query_plan do result_set = connection.select_all(sanitize_sql(sql), "#{name} Load", binds) @@ -57,8 +56,6 @@ module ActiveRecord # # * +sql+ - An SQL statement which should return a count query from the database, see the example below. # - # ==== Examples - # # Product.count_by_sql "SELECT COUNT(*) FROM sales s, customers c WHERE s.customer_id = c.id" def count_by_sql(sql) logging_query_plan do |