Open PawelSuwinski opened 1 year ago
The generator is using an interface: https://github.com/api-platform/schema-generator/blob/ed297c7e7c7670c23102176b22667efcaab8dcac/src/TypesGenerator.php#L87 You can already use an alternate inflector.
However having an additional config parameter could be a good idea.
Description
Singularized form of adder/remover method name for collections is hardcoded to the first item from the list returned by EnglishInflector:
https://github.com/api-platform/schema-generator/blob/ed297c7e7c7670c23102176b22667efcaab8dcac/src/Model/Class_.php#L335
If transformation is ambiguous inflector return list of proposition, and in some cases first one it not we want to, for example:
How to reproduce
gives:
Possible Solution