mirror of
https://gh.wpcy.net/https://github.com/WordPress/WordPress-Coding-Standards.git
synced 2026-04-23 20:33:18 +08:00
This new PHPCS 3.9.0 sniff will flag code which contains a `||` and a `&&` operator in the same condition and their precedence is not clarified via parenthesis. This should allow for users of WPCS to find/prevent some bugs in code. I'd personally would **_highly_** recommend for WP Core to also use this sniff, but I suspect that will need due discussion/Make post/handbook change. Note: running this sniff on WP Core as-is, would (to my surprise) not actually trigger any new errors. Includes updating a code snippet in the Ruleset test to comply. |
||
|---|---|---|
| .. | ||
| RulesetCheck | ||
| bootstrap.php | ||