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

Fix order of BracesFixer and ClassDefinitionFixer #5567

Merged
merged 1 commit into from
Mar 22, 2021

Conversation

Daeroni
Copy link
Contributor

@Daeroni Daeroni commented Mar 22, 2021

If BracesFixer is configured with "position_after_functions_and_oop_constructs": "same", it would be overwritten by ClassDefinitionFixer putting the brace on the next line unless the ClassDefinitionFixer is run before BracesFixer.

It seems ClassDefinitionFixer was previously run implicitly before BracesFixer, but 701708e changed the priority of BracesFixer from negative to positive and the order of the two fixers were reversed.

@coveralls
Copy link

coveralls commented Mar 22, 2021

Coverage Status

Coverage increased (+0.0004%) to 91.849% when pulling 01d34da on Daeroni:fix-class-definiton-braces into d617223 on FriendsOfPHP:2.18.

@keradus
Copy link
Member

keradus commented Mar 22, 2021

Thanks for PR, @Daeroni !
Would you mind to rebase ?

@keradus keradus added this to the 2.18.5 milestone Mar 22, 2021
@keradus
Copy link
Member

keradus commented Mar 22, 2021

Thank you @Daeroni.

@keradus keradus merged commit 61b9090 into PHP-CS-Fixer:2.18 Mar 22, 2021
@carlobeltrame
Copy link

@keradus Would you mind publishing a release with this fix? Thanks!

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

Successfully merging this pull request may close these issues.

None yet

5 participants