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

Improve default PHPMD checks #29

Open
josephdpurcell opened this issue Nov 13, 2016 · 2 comments
Open

Improve default PHPMD checks #29

josephdpurcell opened this issue Nov 13, 2016 · 2 comments

Comments

@josephdpurcell
Copy link
Contributor

Problem

By default, PHPMD has the following two checks which I believe are problematic:

  • The camelCase variable names apply to Zend and Symfony but not Drupal and Wordpress.
  • Avoiding "else" statements is controversial: I don't believe there is consensus that the use of else statements correlates with poor code. And it is a little redundant in that it would be caught by Cyclomatic Complexity and NPath Complexity metrics.

Proposed Resolution

  • Turn off the CamelCaseClassName, CamelCasePropertyName, CamelCaseMethodName, CamelCaseParameterName, CamelCaseVariableName checks by default.
  • Turn off the ElseExpression check by default.
@dblandin
Copy link
Contributor

dblandin commented Mar 6, 2017

This proposal sounds great to me 👍

@purplefish32
Copy link

👍

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

3 participants