Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Symfony pluralization bugs with "Device" #13613

Closed
malavsky opened this issue Feb 6, 2015 · 6 comments
Closed

Symfony pluralization bugs with "Device" #13613

malavsky opened this issue Feb 6, 2015 · 6 comments

Comments

@malavsky
Copy link

malavsky commented Feb 6, 2015

"Device" pluralized to "Devouse" and also "feedback" to "foodback"

symfony 2.6.4

@aivus
Copy link
Contributor

aivus commented Feb 6, 2015

👍

@wouterj
Copy link
Member

wouterj commented Feb 7, 2015

I can confirm feedback -> foodback, but device -> devouse works perfectly (at least in 2.3). See also #13618

@malavsky
Copy link
Author

malavsky commented Feb 7, 2015

I have Component entity with oneToMany relation to ComponetToDevice entity. For admin I use SonataAdminBundle. When I build a form to edit Component entity with sonata_type_collection type for 'componentToDevice' field . I got a error that symfony can not find addComponentToDevice or setComponentToDevice and propouse me setComponentToDevouce and etc.

@WhiteEagle88
Copy link

@malavsky You got a error that symfony can not find "addComponentToDevouce()"/"removeComponentToDevouce()", "setComponentToDevouce()", "componentToDevouce()", "__set()" or "__call()" exist and have public access in class "...\MainBundle\Entity\Component"."

@aivus
Copy link
Contributor

aivus commented Feb 10, 2015

but device -> devouse works perfectly

@wouterj do you really think is it correct behavior?
device should stay device after StringUtil::singularify()

@wouterj
Copy link
Member

wouterj commented Feb 10, 2015

@aivus the plural of "device" is "devices". StringUtil::singularify('devices') returns 3 options, one of them is "device" (the correct one). See also my PR.

fabpot added a commit that referenced this issue Feb 16, 2015
…arization (WouterJ)

This PR was merged into the 2.3 branch.

Discussion
----------

[PropertyAccess] Fixed invalid feedback -> foodback singularization

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #13613
| License       | MIT
| Doc PR        | -

Commits
-------

bc50125 Fixed invalid feedback -> foodback singularization
@fabpot fabpot closed this as completed Feb 16, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants