Skip to content

Commit

Permalink
Update class-phpcs-runner.php
Browse files Browse the repository at this point in the history
add guard to line 126
  • Loading branch information
afragen authored Dec 15, 2023
1 parent 0c9e2d1 commit ee08761
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions inc/class-phpcs-runner.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ protected function get_args(): array {
*/
public function run() {
// Backup the original command line arguments.
$orig_cmd_args = $_SERVER['argv'];
$orig_cmd_args = $_SERVER['argv'] ?? [];

// Create the default arguments for PHPCS.
$defaults = [
Expand Down Expand Up @@ -225,4 +225,4 @@ protected function reset_php_codesniffer_config(): void {
$overridden_defaults->setAccessible( false );
}
}
}
}

0 comments on commit ee08761

Please sign in to comment.