Skip to content

Commit a9b5383

Browse files
committed
bug symfony#43834 [Inflector] Fix inflector for "zombies" (acodispo)
This PR was merged into the 4.4 branch. Discussion ---------- [Inflector] Fix inflector for "zombies" The word "zombies" should be singularized to "zombie" (rather than "zomby"). We provide a PLURAL_MAP for this case, as well as a test. | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | See symfony#43789 | License | MIT Commits ------- 870d342 [Inflector] Fix inflector for "zombies"
2 parents 078df14 + 870d342 commit a9b5383

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

src/Symfony/Component/Inflector/Inflector.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,9 @@ final class Inflector
6060
// indices (index), appendices (appendix), prices (price)
6161
['seci', 4, false, true, ['ex', 'ix', 'ice']],
6262

63+
// zombies (zombie)
64+
['seibmoz', 7, true, true, 'zombie'],
65+
6366
// selfies (selfie)
6467
['seifles', 7, true, true, 'selfie'],
6568

src/Symfony/Component/Inflector/Tests/InflectorTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,7 @@ public function singularizeProvider()
151151
['trees', 'tree'],
152152
['waltzes', ['waltz', 'waltze']],
153153
['wives', 'wife'],
154+
['zombies', 'zombie'],
154155

155156
// test casing: if the first letter was uppercase, it should remain so
156157
['Men', 'Man'],

0 commit comments

Comments
 (0)