diff --git a/src/Symfony/Component/PropertyAccess/StringUtil.php b/src/Symfony/Component/PropertyAccess/StringUtil.php index 29da09755cd1..5fa1b1734f8b 100644 --- a/src/Symfony/Component/PropertyAccess/StringUtil.php +++ b/src/Symfony/Component/PropertyAccess/StringUtil.php @@ -197,7 +197,7 @@ public static function singularify($plural) } // Convert teeth to tooth, feet to foot - if (false !== ($pos = strpos($plural, 'ee')) && strlen($plural) > 3) { + if (false !== ($pos = strpos($plural, 'ee')) && strlen($plural) > 3 && 'feedback' !== $plural) { return substr_replace($plural, 'oo', $pos, 2); } diff --git a/src/Symfony/Component/PropertyAccess/Tests/StringUtilTest.php b/src/Symfony/Component/PropertyAccess/Tests/StringUtilTest.php index a9c07162fe6a..7c6376dbd6a1 100644 --- a/src/Symfony/Component/PropertyAccess/Tests/StringUtilTest.php +++ b/src/Symfony/Component/PropertyAccess/Tests/StringUtilTest.php @@ -59,6 +59,7 @@ public function singularifyProvider() array('data', array('daton', 'datum')), array('days', 'day'), array('discos', 'disco'), + array('devices', array('devex', 'devix', 'device')), array('drives', 'drive'), array('drivers', 'driver'), array('dwarves', array('dwarf', 'dwarve', 'dwarff')), @@ -67,6 +68,7 @@ public function singularifyProvider() array('emphases', array('emphas', 'emphase', 'emphasis')), array('faxes', 'fax'), array('feet', 'foot'), + array('feedback', 'feedback'), array('foci', 'focus'), array('focuses', array('focus', 'focuse', 'focusis')), array('formulae', 'formula'),