private function H5PEditorAjaxImport::getContentTypeCache in Opigno module 8
Same name and namespace in other branches
- 3.x src/H5PImportClasses/H5PEditorAjaxImport.php \Drupal\opigno_module\H5PImportClasses\H5PEditorAjaxImport::getContentTypeCache()
Gets content type cache for globally available libraries and the order in which they have been used by the author
Parameters
bool $cacheOutdated The cache is outdated and not able to update:
1 call to H5PEditorAjaxImport::getContentTypeCache()
- H5PEditorAjaxImport::h5pLibariesList in src/
H5PImportClasses/ H5PEditorAjaxImport.php - Gets the list of libraries.
File
- src/
H5PImportClasses/ H5PEditorAjaxImport.php, line 58
Class
- H5PEditorAjaxImport
- Class H5PEditorAjaxMigrate.
Namespace
Drupal\opigno_module\H5PImportClassesCode
private function getContentTypeCache($cacheOutdated = FALSE) {
$canUpdateOrInstall = $this->core->h5pF
->hasPermission(\H5PPermission::INSTALL_RECOMMENDED) || $this->core->h5pF
->hasPermission(\H5PPermission::UPDATE_LIBRARIES);
return array(
'outdated' => $cacheOutdated && $canUpdateOrInstall,
'libraries' => $this->editor
->getLatestGlobalLibrariesData(),
'recentlyUsed' => $this->editor->ajaxInterface
->getAuthorsRecentlyUsedLibraries(),
'apiVersion' => array(
'major' => \H5PCore::$coreApi['majorVersion'],
'minor' => \H5PCore::$coreApi['minorVersion'],
),
'details' => $this->core->h5pF
->getMessages('info'),
);
}