Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion WordPress/Sniffs/NamingConventions/PrefixAllGlobalsSniff.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,9 @@ final class PrefixAllGlobalsSniff extends AbstractFunctionParameterSniff {
/**
* Minimal number of characters the prefix needs in order to be valid.
*
* @since n.e.x.t.
* @since 2.2.0
*
* @link https://github.com/WordPress/WordPress-Coding-Standards/issues/1733 Issue 1733.
* @link https://github.com/WordPress/WordPress-Coding-Standards/issues/2467 Issue 2467.
*
* @var int
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
// phpcs:set WordPress.NamingConventions.PrefixAllGlobals prefixes[] wp
function wp_do_something() {}

// phpcs:set WordPress.NamingConventions.PrefixAllGlobals prefixes[] ^%&
function ^%&_do_something() {}
// phpcs:set WordPress.NamingConventions.PrefixAllGlobals prefixes[] ^%&%
function ^%&%_do_something() {}

// Now let's set the real prefixes we want to test for.
// phpcs:set WordPress.NamingConventions.PrefixAllGlobals prefixes[] acronym,tgmpa
Expand Down