mirror of
https://github.com/Mibew/mibew.git
synced 2024-11-15 16:44:11 +03:00
Add PluginManager::hasPlugin method
This commit is contained in:
parent
5282e789ba
commit
2bdfebc428
@ -77,6 +77,18 @@ class PluginManager
|
||||
return $this->loadedPlugins[$plugin_name];
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if there is an instance of the plugin in the manager.
|
||||
*
|
||||
* @param string $plugin_name Name of the plugin to check
|
||||
* @return boolean True if the plugin exists in the manager and false
|
||||
* otherwise.
|
||||
*/
|
||||
public function hasPlugin($plugin_name)
|
||||
{
|
||||
return isset($this->loadedPlugins[$plugin_name]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns associative array of loaded plugins.
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user