function _get_modules in General Data Protection Regulation 7
Same name and namespace in other branches
- 8.2 gdpr.module \_get_modules()
- 8 gdpr.module \_get_modules()
Returns cached module data from module info files.
Return value
array Array of module data
2 calls to _get_modules()
- _get_gdpr_module_description in ./
gdpr.module - Returns a HTML makrup for gdpr_modules checkpoint description.
- _get_module_list in ./
gdpr.module - Returns a HTML makrup for data_collecting modules checkpoint description.
File
- ./
gdpr.module, line 580 - Contains hook implementations and shared functions.
Code
function _get_modules() {
$cache = cache_get('modules_list');
if ($cache) {
return $cache->data;
}
else {
$modules_list_raw = system_rebuild_module_data();
$modules_list = [];
foreach ($modules_list_raw as $module) {
$modules_list[$module->name] = [
'status' => $module->status,
'name' => $module->info['name'],
];
}
cache_set('modules_list', $modules_list);
return $modules_list;
}
}