Skip to content

Commit

Permalink
Fix doc typo. Move extend self so it's more immediately obvious. Requ…
Browse files Browse the repository at this point in the history
…ire inflections from load path.
  • Loading branch information
jeremy committed Jun 6, 2008
1 parent 1dbfe97 commit 0ccd0b5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions activesupport/lib/active_support/inflector.rb
Expand Up @@ -10,6 +10,8 @@ module ActiveSupport
# If you discover an incorrect inflection and require it for your application, you'll need
# to correct it yourself (explained below).
module Inflector
extend self

# A singleton instance of this class is yielded by Inflector.inflections, which can then be used to specify additional
# inflection rules. Examples:
#
Expand Down Expand Up @@ -91,8 +93,6 @@ def clear(scope = :all)
end
end

extend self

# Yields a singleton instance of Inflector::Inflections so you can specify additional
# inflector rules.
#
Expand Down Expand Up @@ -134,7 +134,7 @@ def pluralize(word)
# "posts".singularize # => "post"
# "octopi".singularize # => "octopus"
# "sheep".singluarize # => "sheep"
# "word".singluarize # => "word"
# "word".singularize # => "word"
# "the blue mailmen".singularize # => "the blue mailman"
# "CamelOctopi".singularize # => "CamelOctopus"
def singularize(word)
Expand Down Expand Up @@ -307,4 +307,4 @@ def ordinalize(number)
end
end

require File.dirname(__FILE__) + '/inflections'
require 'active_support/inflections'

0 comments on commit 0ccd0b5

Please sign in to comment.