-
-
Save tommcfarlin/052ce1b88ebec6ab7e27da5b35e3bcb2 to your computer and use it in GitHub Desktop.
[WordPress] Ignore Coding Standards in PHP CodeSniffer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function highlight_draft_submenu( $parent_file ) { | |
global $submenu_file; | |
// Only update the submenu file value if we're on the Scheduled page. | |
if ( 'draft' === get_query_var( 'post_status' ) ) { | |
/** | |
* Removing unnecessary code for the purposes of the demo. Assume | |
* there is an associative array of key/value pairs referened by | |
* a variabled named `$args`. | |
*/ | |
// @codingStandardsIgnoreStart | |
$submenu_file = add_query_arg( $args, $url ); | |
// @codingStandardsIgnoreEnd | |
} | |
return $parent_file; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment