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

Create sniff to ensure empty after { and before } in class/interface/trait #45

Open
aik099 opened this issue Dec 9, 2014 · 0 comments

Comments

@aik099
Copy link
Owner

aik099 commented Dec 9, 2014

There is a Squiz.WhiteSpace.FunctionSpacing sniff, that checks, that:

  • there 1 line before/after function declaration
  • there is an empty line after last function declaration in a class (only since PHPCS 2.2.0, squizlabs/PHP_CodeSniffer@4bc2418)

I mistakenly assumed that check was made to ensure 1 empty line after class opening brace.


Need to write sniff that will:

  • ensure 1 empty line after { (basically line after line where { is placed should be empty)
  • ensure 1 empty line before } (basically line before line where } is placed should be empty)
@aik099 aik099 added the type-bug label Dec 9, 2014
@aik099 aik099 changed the title Check for empty line before closing class brace Create sniff to ensure empty after { and before } in class/interface/trait Dec 12, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant