Skip to content

Commit 5704d63

Browse files
committed
fix PHPCS
1 parent b9e04bf commit 5704d63

2 files changed

Lines changed: 8 additions & 6 deletions

File tree

composer.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,11 @@
1414
"config": {
1515
"optimize-autoloader": true,
1616
"preferred-install": { "*": "dist" },
17-
"sort-packages": true
17+
"sort-packages": true,
18+
"allow-plugins": {
19+
"phpro/grumphp-shim": true,
20+
"dealerdirect/phpcodesniffer-composer-installer": true
21+
}
1822
},
1923
"require-dev": {
2024
"dealerdirect/phpcodesniffer-composer-installer": "v0.7.1",

default-http-headers.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@ function wp_headers( array $headers ): array {
6161
$csp_header = defined( 'CSP_REPORT_ONLY' ) && CSP_REPORT_ONLY ? 'Content-Security-Policy-Report-Only' : 'Content-Security-Policy';
6262
$csp_headers_array[ $csp_header ] = get_prepare_csp( $csp );
6363

64-
6564
$custom_headers_array = [];
6665

6766
/**$custom_headers_array = [
@@ -124,10 +123,9 @@ function get_csp_headers(): array {
124123
'object-src' => '\'none\'',
125124
];
126125

127-
if ( 'production' === WP_ENV ) {
126+
//if ( 'production' === WP_ENV ) {
128127
//$csp = [];
129-
}
130-
128+
//}
131129

132130
return apply_filters( 'csp_headers', $csp );
133-
}
131+
}

0 commit comments

Comments
 (0)