Commit ca7b56e7 authored by webchick's avatar webchick

#561452 follow-up by David_Rothstein: Use helper functions rather than file...

#561452 follow-up by David_Rothstein: Use helper functions rather than file scans to retrieve module data on permissions page.
parent 9ad53c52
......@@ -117,7 +117,7 @@ public static function canUpdate($project_name) {
public function postInstall() {
// Update the system table.
clearstatcache();
drupal_static_reset('_system_get_theme_data');
drupal_static_reset('_system_rebuild_theme_data');
_system_rebuild_theme_data();
// Active the theme
......
......@@ -650,12 +650,12 @@ function user_admin_permissions($form, $form_state, $rid = NULL) {
);
// Render role/permission overview:
$options = array();
$module_info = system_get_info('module');
$hide_descriptions = !system_admin_compact_mode();
foreach (module_implements('permission') as $module) {
if ($permissions = module_invoke($module, 'permission')) {
$info = drupal_parse_info_file(drupal_get_path('module', $module) . "/$module.info");
$form['permission'][] = array(
'#markup' => $info['name'],
'#markup' => $module_info[$module]['name'],
'#id' => $module,
);
foreach ($permissions as $perm => $perm_item) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment