Tribe__Dependency::has_requisite_plugins( array $plugins_required = array() )
Checks if each plugin is active and exceeds the specified version number
Contents
Parameters
- $plugins_required
-
(array) (Optional) Each item is a 'class_name' => 'min version' pair. Min ver can be null.
Default value: array()
Return
(bool)
Source
File: src/Tribe/Dependency.php
public function has_requisite_plugins( $plugins_required = array() ) {
foreach ( $plugins_required as $class => $version ) {
// Return false if the plugin is not set or is a lesser version
if ( ! $this->is_plugin_active( $class ) ) {
return false;
}
if ( null !== $version && ! $this->is_plugin_version( $class, $version ) ) {
return false;
}
}
return true;
}