Skip to content

[Config] Fix array sort on normalization in edge case #17129

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

Merged
merged 1 commit into from
Dec 26, 2015

Conversation

romainneutron
Copy link
Contributor

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets N/A
License MIT
Doc PR N/A

@romainneutron
Copy link
Contributor Author

What solved by this issue:

At the moment, if you define a bundle configuration like this:

config:
   anything-with-a-dash-and-no-underscore: value
   anythingelse: othervalue

It is resolved like this:

["config"]=>
  array(2) {
    ["anythingelse"] => string(10) "othervalue"
    ["anything_with_a_dash_and_no_underscore"] => string(5) "value"
  }

instead of

["config"]=>
  array(2) {
    ["anything_with_a_dash_and_no_underscore"] => string(5) "value"
    ["anythingelse"] => string(10) "othervalue"
  }

This is particularly a problem when defining prioritized rules :)

You can find the details of the issue at nelmio/NelmioSecurityBundle#72

@nicolas-grekas
Copy link
Member

👍

1 similar comment
@tucksaun
Copy link
Contributor

👍

@xabbuh
Copy link
Member

xabbuh commented Dec 26, 2015

👍

Status: Reviewed

@fabpot
Copy link
Member

fabpot commented Dec 26, 2015

Thank you @romainneutron.

@fabpot fabpot merged commit eca41a8 into symfony:2.3 Dec 26, 2015
fabpot added a commit that referenced this pull request Dec 26, 2015
…ainneutron)

This PR was merged into the 2.3 branch.

Discussion
----------

[Config] Fix array sort on normalization in edge case

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

Commits
-------

eca41a8 [Config] Fix array sort on normalization in edge case
@romainneutron romainneutron deleted the fix-config-array-order branch December 28, 2015 09:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants