Skip to content
This repository
Browse code

Fix an issue with inflection where my_analyses (in plular form) incor…

…rectly converted to my_analyasis(in singular form).
  • Loading branch information...
commit bc51ad957a22a7326a6d723cd75bbc97cbeaa0f6 1 parent 78b6fdd
Anuj Dutta authored May 16, 2012
2  activesupport/lib/active_support/inflections.rb
@@ -26,7 +26,7 @@ module ActiveSupport
26 26
     inflect.singular(/(ss)$/i, '\1')
27 27
     inflect.singular(/(n)ews$/i, '\1ews')
28 28
     inflect.singular(/([ti])a$/i, '\1um')
29  
-    inflect.singular(/((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)(sis|ses)$/i, '\1\2sis')
  29
+    inflect.singular(/((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)(sis|ses)$/i, '\1sis')
30 30
     inflect.singular(/(^analy)(sis|ses)$/i, '\1sis')
31 31
     inflect.singular(/([^f])ves$/i, '\1fe')
32 32
     inflect.singular(/(hive)s$/i, '\1')
1  activesupport/test/inflector_test_cases.rb
@@ -47,6 +47,7 @@ module InflectorTestCases
47 47
     "medium"      => "media",
48 48
     "stadium"     => "stadia",
49 49
     "analysis"    => "analyses",
  50
+    "my_analysis" => "my_analyses",
50 51
 
51 52
     "node_child"  => "node_children",
52 53
     "child"       => "children",

0 notes on commit bc51ad9

Please sign in to comment.
Something went wrong with that request. Please try again.