Modified inflector helper to properly pluralize words that end in 'ch' or 'sh'
http://codeigniter.com/bug_tracker/bug/9384/
diff --git a/system/helpers/inflector_helper.php b/system/helpers/inflector_helper.php
index e65968a..8db4f3d 100644
--- a/system/helpers/inflector_helper.php
+++ b/system/helpers/inflector_helper.php
@@ -91,6 +91,17 @@
$vowels = array('a', 'e', 'i', 'o', 'u');
$str = in_array(substr($str, -2, 1), $vowels) ? $str.'s' : substr($str, 0, -1).'ies';
}
+ elseif ($end == 'h')
+ {
+ if (substr($str, -2) == 'ch' || substr($str, -2) == 'sh')
+ {
+ $str .= 'es';
+ }
+ else
+ {
+ $str .= 's';
+ }
+ }
elseif ($end == 's')
{
if ($force == TRUE)