Automattic\WooCommerce
Packages::package_exists()
Checks a package exists by looking for it's directory.
Method of the class: Packages{}
No Hooks.
Return
true|false
.
Usage
$result = Packages::package_exists( $package );
- $package(string) (required)
- Package name.
Packages::package_exists() Packages::package exists code WC 9.4.2
public static function package_exists( $package ) { return file_exists( dirname( __DIR__ ) . '/packages/' . $package ); }