Skip to content

Commit

Permalink
remove duplicate functions
Browse files Browse the repository at this point in the history
  • Loading branch information
arunshenoy99 committed Oct 22, 2024
1 parent 9a5bfee commit d6e8156
Showing 1 changed file with 0 additions and 18 deletions.
18 changes: 0 additions & 18 deletions includes/Services/PluginInstaller.php
Original file line number Diff line number Diff line change
Expand Up @@ -371,24 +371,6 @@ public static function is_nfd_slug( $plugin ) {
return false;
}

/**
* Determines if a plugin has already been installed.
*
* @param string $plugin_path Path to the plugin's header file.
* @return boolean
*/
public static function is_plugin_installed( $plugin_path ) {
if ( ! function_exists( 'get_plugins' ) ) {
require_once ABSPATH . 'wp-admin/includes/plugin.php';
}
$all_plugins = \get_plugins();
if ( ! empty( $all_plugins[ $plugin_path ] ) ) {
return true;
} else {
return false;
}
}

/**
* Get the type of plugin slug. Ref: includes/Data/Plugins.php for the different types.
*
Expand Down

0 comments on commit d6e8156

Please sign in to comment.