Skip to content

Commit

Permalink
Remove trailing commas in function calls. Triggers a fatal error in P…
Browse files Browse the repository at this point in the history
…HP < 7.3
  • Loading branch information
wpscholar committed Jan 10, 2023
1 parent 8d27917 commit 999332b
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion includes/Data/Plugins.php
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ public static function get() {
public static function get_squashed() {
return array_merge(
array_filter( self::$wp_slugs, array( __CLASS__, 'check_approved' ) ) ,
array_filter( self::$nfd_slugs, array( __CLASS__, 'check_approved' ) ) ,
array_filter( self::$nfd_slugs, array( __CLASS__, 'check_approved' ) )
);
}

Expand Down
4 changes: 2 additions & 2 deletions includes/RestApi/PluginsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -306,13 +306,13 @@ public function set_site_features( \WP_REST_Request $request ) {
PluginInstallTaskManager::add_to_queue(
new PluginInstallTask(
$plugin,
true,
true
)
);
} else {
PluginUninstallTaskManager::add_to_queue(
new PluginUninstallTask(
$plugin,
$plugin
)
);
}
Expand Down
2 changes: 1 addition & 1 deletion includes/RestApi/Themes/ThemeVariationsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public function get_theme_variations( \WP_REST_Request $request ) {

return array_merge(
array( $active_variation_global_style ),
self::get_style_variations(),
self::get_style_variations()
);
}

Expand Down
4 changes: 2 additions & 2 deletions includes/TaskManagers/PluginUninstallTaskManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,9 @@ public static function add_to_queue( PluginUninstallTask $plugin_uninstall_task
$position_in_queue = PluginInstallTaskManager::status( $plugin_uninstall_task->get_slug() );
if ( $position_in_queue !== false && $position_in_queue !== 0 ) {
PluginInstallTaskManager::remove_from_queue(
$plugin_uninstall_task->get_slug(),
$plugin_uninstall_task->get_slug()
);

return true;
}

Expand Down

0 comments on commit 999332b

Please sign in to comment.