public static function AssetManager::getPluginsVersion in CKEditor Media Embed Plugin 8
Get the plugins version.
Parameters
\Drupal\Core\Asset\LibraryDiscoveryInterface $library_discovery: The library discovery service to use for retrieving information about the CKeditor library.
\Drupal\Core\Config\ConfigFactory $config_factory: The config factory service to use for retrieving configuration information about CKeditor Media Embed.
string $path: The path to the library yml file, from the root. Defaults to 'core'.
string $extension: The extension type of the library file. Defaults to 'core'.
Return value
string The version number of the currently installed CKEditor plugins or if not installed the version of the installed CKEditor.
4 calls to AssetManager::getPluginsVersion()
- AssetManagerTest::testGetPluginsVersion in tests/
src/ Unit/ AssetManagerTest.php - Tests \Drupal\ckeditor_media_embed\AssetManager::getPluginsVersion().
- CKEditorVersionAwarePluginBase::versionCompare in src/
CKEditorVersionAwarePluginBase.php - Compares the specified version against the currently installed version.
- ckeditor_media_embed_ckeditor_plugin_info_alter in ./
ckeditor_media_embed.module - Implements hook_ckeditor_plugin_info_alter().
- ckeditor_media_embed_requirements in ./
ckeditor_media_embed.install - Implements hook_requirements().
File
- src/
AssetManager.php, line 167
Class
- AssetManager
- The AssetManager facade for managing CKEditor plugins.
Namespace
Drupal\ckeditor_media_embedCode
public static function getPluginsVersion(LibraryDiscoveryInterface $library_discovery, ConfigFactory $config_factory, $path = 'core', $extension = 'core') {
$version = self::getPluginsInstalledVersion($config_factory);
if (empty($version)) {
$version = self::getCKEditorVersion($library_discovery, $config_factory);
}
return $version;
}