Skip to content

Commit

Permalink
Core: move BacktickOperator sniff from Extra to Core
Browse files Browse the repository at this point in the history
> 1. Use of the backtick operator is not allowed.

Refs:
* https://make.wordpress.org/core/2020/03/20/updating-the-coding-standards-for-modern-php/ - Shell Commands section
* WordPress/WordPress-Coding-Standards 646
  • Loading branch information
jrfnl committed Aug 10, 2022
1 parent a7afa26 commit 7491af3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
3 changes: 3 additions & 0 deletions WordPress-Core/ruleset.xml
Original file line number Diff line number Diff line change
Expand Up @@ -558,6 +558,9 @@
<!-- Covers rule: The PHP native __...__ magic constants should be in uppercase when used. -->
<rule ref="Universal.Constants.UppercaseMagicConstants"/>

<!-- Covers rule: Use of the backtick operator is not allowed. -->
<rule ref="Generic.PHP.BacktickOperator"/>




Expand Down
3 changes: 0 additions & 3 deletions WordPress-Extra/ruleset.xml
Original file line number Diff line number Diff line change
Expand Up @@ -96,9 +96,6 @@
https://github.com/WordPress/WordPress-Coding-Standards/issues/1146 -->
<rule ref="WordPress.WP.EnqueuedResourceParameters"/>

<!-- Discourage use of the backtick operator (execution of shell commands).
https://github.com/WordPress/WordPress-Coding-Standards/pull/646 -->
<rule ref="Generic.PHP.BacktickOperator"/>

<!-- Check for PHP Parse errors.
https://github.com/WordPress/WordPress-Coding-Standards/issues/522 -->
Expand Down

0 comments on commit 7491af3

Please sign in to comment.