Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix PHPCS checks on unwritable filesystems. #813

Merged
merged 1 commit into from
Dec 2, 2024
Merged
Changes from all commits
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
4 changes: 2 additions & 2 deletions includes/Checker/Checks/Abstract_PHP_CodeSniffer_Check.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@

// Override installed_paths to load custom sniffs.
if ( isset( $args['installed_paths'] ) && is_array( $args['installed_paths'] ) ) {
Config::setConfigData( 'installed_paths', implode( ',', $args['installed_paths'] ) );
Config::setConfigData( 'installed_paths', implode( ',', $args['installed_paths'] ), true );

Check warning on line 103 in includes/Checker/Checks/Abstract_PHP_CodeSniffer_Check.php

View check run for this annotation

Codecov / codecov/patch

includes/Checker/Checks/Abstract_PHP_CodeSniffer_Check.php#L103

Added line #L103 was not covered by tests
}

// Create the default arguments for PHPCS.
Expand All @@ -121,7 +121,7 @@
}

// Reset installed_paths.
Config::setConfigData( 'installed_paths', $installed_paths );
Config::setConfigData( 'installed_paths', $installed_paths, true );

// Restore original arguments.
$_SERVER['argv'] = $orig_cmd_args;
Expand Down
Loading