mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
removes Examples headers introduced in 9b96de6
Example headers are discouraged in the API guidelines. Code just flows with the text. They may be good in places where there's a lot of stuff and structure may add clarity
This commit is contained in:
parent
8bbc5b4f5f
commit
6ce844a3c1
1 changed files with 4 additions and 10 deletions
|
@ -41,9 +41,6 @@ module ActiveSupport
|
|||
# Allows you to add shortcut so that you don't have to refer to attribute through config.
|
||||
# Also look at the example for config to contrast.
|
||||
#
|
||||
#
|
||||
# ==== Example
|
||||
#
|
||||
# class User
|
||||
# include ActiveSupport::Configurable
|
||||
# config_accessor :allowed_access
|
||||
|
@ -67,24 +64,21 @@ module ActiveSupport
|
|||
end
|
||||
|
||||
# Reads and writes attributes from a configuration <tt>OrderedHash</tt>.
|
||||
#
|
||||
#
|
||||
# ==== Example
|
||||
# require 'active_support/configurable'
|
||||
#
|
||||
# require 'active_support/configurable'
|
||||
#
|
||||
# class User
|
||||
# include ActiveSupport::Configurable
|
||||
# end
|
||||
# end
|
||||
#
|
||||
# user = User.new
|
||||
#
|
||||
#
|
||||
# user.config.allowed_access = true
|
||||
# user.config.level = 1
|
||||
#
|
||||
# user.config.allowed_access # => true
|
||||
# user.config.level # => 1
|
||||
#
|
||||
#
|
||||
def config
|
||||
@_config ||= self.class.config.inheritable_copy
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue