Trivial documentation fix for ActiveModel::Naming comment.

This commit is contained in:
Dennis Taylor 2012-11-09 11:23:51 -08:00
parent 38411b89fc
commit ba291a67df
1 changed files with 2 additions and 2 deletions

View File

@ -263,10 +263,10 @@ module ActiveModel
# namespaced models regarding whether it's inside isolated engine.
#
# # For isolated engine:
# ActiveModel::Naming.route_key(Blog::Post) #=> post
# ActiveModel::Naming.singular_route_key(Blog::Post) #=> post
#
# # For shared engine:
# ActiveModel::Naming.route_key(Blog::Post) #=> blog_post
# ActiveModel::Naming.singular_route_key(Blog::Post) #=> blog_post
def self.singular_route_key(record_or_class)
model_name_from_record_or_class(record_or_class).singular_route_key
end