Commit f7cd2518 authored by Dries's avatar Dries
Browse files

- Patch #356747 by chx: fix hidden module dependencies.

parent f088ccfb
...@@ -6,4 +6,4 @@ version = VERSION ...@@ -6,4 +6,4 @@ version = VERSION
core = 7.x core = 7.x
files[] = taxonomy_test.module files[] = taxonomy_test.module
hidden[] = TRUE hidden[] = TRUE
dependencies[] = Taxonomy dependencies[] = taxonomy
...@@ -643,12 +643,15 @@ function system_modules($form_state = array()) { ...@@ -643,12 +643,15 @@ function system_modules($form_state = array()) {
// Mark dependents disabled so user can not remove modules being depended on. // Mark dependents disabled so user can not remove modules being depended on.
$dependents = array(); $dependents = array();
foreach ($module->info['dependents'] as $dependent) { foreach ($module->info['dependents'] as $dependent) {
if ($files[$dependent]->status == 1) { // Hidden modules are unset already.
$extra['dependents'][] = t('@module (<span class="admin-enabled">enabled</span>)', array('@module' => $files[$dependent]->info['name'])); if (isset($files[$dependent])) {
$extra['disabled'] = TRUE; if ($files[$dependent]->status == 1) {
} $extra['dependents'][] = t('@module (<span class="admin-enabled">enabled</span>)', array('@module' => $files[$dependent]->info['name']));
else { $extra['disabled'] = TRUE;
$extra['dependents'][] = t('@module (<span class="admin-disabled">disabled</span>)', array('@module' => $files[$dependent]->info['name'])); }
else {
$extra['dependents'][] = t('@module (<span class="admin-disabled">disabled</span>)', array('@module' => $files[$dependent]->info['name']));
}
} }
} }
$form['modules'][$module->info['package']][$filename] = _system_modules_build_row($module->info, $extra); $form['modules'][$module->info['package']][$filename] = _system_modules_build_row($module->info, $extra);
......
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