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

[PropertyInfo] Respect property name case when guessing from public method name #33948

Merged
merged 1 commit into from Oct 13, 2019

Conversation

@antograssiot
Copy link
Contributor

antograssiot commented Oct 11, 2019

Q A
Branch? 3.4
Bug fix? yes
New feature? no
Deprecations? no
Tickets Fix #32656
License MIT
Doc PR

Using camelCase, with an attribute $aFooBar, naming the getter/setter getAFooBar()/setAFooBar(), returns the property name as AFooBar instead of aFooBar.

Before

Property name 'AFooBar'

After

Property name 'aFooBar' as expected

…ethod name
@antograssiot

This comment has been minimized.

Copy link
Contributor Author

antograssiot commented Oct 11, 2019

Not sure the failing test are related 🤔

@nicolas-grekas nicolas-grekas changed the title [PropertyInfo] Respect property name case when guessing from public m… [PropertyInfo] Respect property name case when guessing from public method name Oct 11, 2019
@nicolas-grekas nicolas-grekas added this to the 3.4 milestone Oct 11, 2019
@fabpot
fabpot approved these changes Oct 13, 2019
@fabpot

This comment has been minimized.

Copy link
Member

fabpot commented Oct 13, 2019

Thank you @antograssiot.

fabpot added a commit that referenced this pull request Oct 13, 2019
…om public method name (antograssiot)

This PR was merged into the 3.4 branch.

Discussion
----------

[PropertyInfo] Respect property name case when guessing from public method name

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #32656
| License       | MIT
| Doc PR        |

Using camelCase, with an attribute `$aFooBar`, naming the getter/setter `getAFooBar()`/`setAFooBar()`,  returns the property name as AFooBar instead of aFooBar.

# Before
Property name `'AFooBar'`

# After
Property name `'aFooBar'` as expected

Commits
-------

843bb76 [PropertyInfo] Respect property name case when guessing from public method name
@fabpot fabpot merged commit 843bb76 into symfony:3.4 Oct 13, 2019
2 of 3 checks passed
2 of 3 checks passed
continuous-integration/travis-ci/pr The Travis CI build failed
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
fabbot.io Your code looks good.
Details
@antograssiot antograssiot deleted the antograssiot:issue-32656 branch Oct 13, 2019
This was referenced Nov 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.