aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYehuda Katz <wycats@gmail.com>2008-05-12 23:41:43 -0700
committerPratik Naik <pratiknaik@gmail.com>2008-05-13 13:50:41 +0100
commit9546ee299952c86329c4854f9b3776382c0575ff (patch)
treee35998a4a3d4a2e9c793af96977e161b9bbd3c3d
parent654e77597ba1e5b64a2be2e5e21cd542aafcfbb0 (diff)
downloadrails-9546ee299952c86329c4854f9b3776382c0575ff.tar.gz
rails-9546ee299952c86329c4854f9b3776382c0575ff.tar.bz2
rails-9546ee299952c86329c4854f9b3776382c0575ff.zip
Add documentation for Inflector.inflections
-rw-r--r--activesupport/lib/active_support/inflector.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/inflector.rb b/activesupport/lib/active_support/inflector.rb
index 68fbf3da35..0fd44324bb 100644
--- a/activesupport/lib/active_support/inflector.rb
+++ b/activesupport/lib/active_support/inflector.rb
@@ -92,6 +92,13 @@ module Inflector
extend self
+ # Yields a singleton instance of Inflector::Inflections so you can specify additional
+ # inflector rules.
+ #
+ # Example:
+ # Inflector.inflections do |inflect|
+ # inflect.uncountable "rails"
+ # end
def inflections
if block_given?
yield Inflections.instance