Fix Generic.Arrays.DisallowShortArraySyntax violations
This commit fixes all violations of the Generic.Arrays.DisallowShortArraySyntax sniff automatically using phpcbf.
This commit is contained in:
parent
94373f78ea
commit
179dd7003e
|
@ -20,7 +20,7 @@ class WC_WCCOM_Site_Installer_Requirements_Check {
|
||||||
* @return bool|WP_Error Does the site met the requirements?
|
* @return bool|WP_Error Does the site met the requirements?
|
||||||
*/
|
*/
|
||||||
public static function met_requirements() {
|
public static function met_requirements() {
|
||||||
$errs = [];
|
$errs = array();
|
||||||
|
|
||||||
if ( ! self::met_wp_cron_requirement() ) {
|
if ( ! self::met_wp_cron_requirement() ) {
|
||||||
$errs[] = 'wp-cron';
|
$errs[] = 'wp-cron';
|
||||||
|
|
|
@ -26,10 +26,10 @@ class Packages {
|
||||||
*
|
*
|
||||||
* @var array Key is the package name/directory, value is the main package class which handles init.
|
* @var array Key is the package name/directory, value is the main package class which handles init.
|
||||||
*/
|
*/
|
||||||
protected static $packages = [
|
protected static $packages = array(
|
||||||
'woocommerce-blocks' => '\\Automattic\\WooCommerce\\Blocks\\Package',
|
'woocommerce-blocks' => '\\Automattic\\WooCommerce\\Blocks\\Package',
|
||||||
'woocommerce-rest-api' => '\\Automattic\\WooCommerce\\RestApi\\Package',
|
'woocommerce-rest-api' => '\\Automattic\\WooCommerce\\RestApi\\Package',
|
||||||
];
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Init the package loader.
|
* Init the package loader.
|
||||||
|
@ -68,7 +68,7 @@ class Packages {
|
||||||
self::missing_package( $package_name );
|
self::missing_package( $package_name );
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
call_user_func( [ $package_class, 'init' ] );
|
call_user_func( array( $package_class, 'init' ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue