Skip to content

Commit d3dd8ec

Browse files
committed
Remove unused parameter for WP_Filesystem_Direct constructor
1 parent cb8db15 commit d3dd8ec

2 files changed

Lines changed: 1 addition & 9 deletions

File tree

src/wp-admin/includes/class-wp-filesystem-direct.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,8 @@ class WP_Filesystem_Direct extends WP_Filesystem_Base {
1919
* Constructor.
2020
*
2121
* @since 2.5.0
22-
*
23-
* @param mixed $arg Not used.
2422
*/
25-
public function __construct( $arg ) {
23+
public function __construct() {
2624
$this->method = 'direct';
2725
$this->errors = new WP_Error();
2826
}

tests/phpstan/baseline.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,6 @@
3131
'count' => 1,
3232
'path' => __DIR__ . '/../../src/wp-admin/includes/class-custom-image-header.php',
3333
];
34-
$ignoreErrors[] = [
35-
'message' => '#^Constructor of class WP_Filesystem_Direct has an unused parameter \\$arg\\.$#',
36-
'identifier' => 'constructor.unusedParameter',
37-
'count' => 1,
38-
'path' => __DIR__ . '/../../src/wp-admin/includes/class-wp-filesystem-direct.php',
39-
];
4034
$ignoreErrors[] = [
4135
'message' => '#^Variable \\$class in empty\\(\\) always exists and is always falsy\\.$#',
4236
'identifier' => 'empty.variable',

0 commit comments

Comments
 (0)